A friend of mine got from a friend of him this snippet, that he asked me to post here:
public Object getDefaultValue(String strType) { if(strType==null) return null; if(strType.equals("STRING")) return ""; if(strType.equals("INTEGER")) return new Integer(0); if(strType.equals("FLOATING")) return new Float(0.0f); if(strType.equals("DATE") || strType.equals("TIMESTAMP")) return new java.util.Date(); if(strType.equals("BOOLEAN")) return new Boolean(true); if(strType.equals("GUID")) return ""; if(strType.equals("OBJECT")) return new Object(); return null; }