max wrote:
how does your reveng.xml file look like ?
I can't reproduce the error any more that both types are mapped to java.io.Serializable. :-( Now both types are mapped to Date or Blob.
This is the working one which maps TIMESTAMP to java.util.Date but also BLOB to java.util.Date.
Code:
<hibernate-reverse-engineering>
<type-mapping>
<sql-type jdbc-type="TIMESTAMP" hibernate-type="java.util.Date" />
<sql-type jdbc-type="DATE" hibernate-type="java.util.Date" />
<sql-type jdbc-type="TIME" hibernate-type="java.util.Date" />
<sql-type jdbc-type="OTHER" hibernate-type="java.util.Date"
not-null="false"/>
<sql-type jdbc-type="CHAR" hibernate-type="java.lang.Boolean"
length="1" />
<sql-type jdbc-type="DECIMAL" hibernate-type="java.lang.Integer"
not-null="true" precision="8" />
<sql-type jdbc-type="DECIMAL" hibernate-type="java.lang.Long"
not-null="true" precision="12" />
<sql-type jdbc-type="DECIMAL" hibernate-type="java.lang.Long"
precision="10" not-null="true" />
<sql-type jdbc-type="DECIMAL" hibernate-type="java.lang.Long"
precision="12" not-null="false" />
</type-mapping>
</hibernate-reverse-engineering>
If I add this
Code:
<sql-type jdbc-type="OTHER" hibernate-type="java.sql.Blob" not-null="false" length="4000"/>
it seems that the length attribute is ignored for "OTHER" types, which is comprehensible.
So the java.io.Serializable error seems to be my fault. If I can reproduce it again, I will post it here. But maybe you have an idea how to differ between two "OTHER" types.
Axel