Hello,
I have in my hbm.xml the following, for when I persist an object, the primary key column auto increments.
<id name="id" type="integer" unsaved-value="null" >
<column name="id" sql-type="integer" not-null="true"/>
<generator class="uuid.hex"/>
</id>
it is throwing an error when executed:
13:25:50,484 ERROR [Configuration] Could not compile the mapping document
net.sf.hibernate.MappingException: Problem trying to set property type by reflection
at net.sf.hibernate.mapping.SimpleValue.setTypeByReflection(SimpleValue.java:183)
at net.sf.hibernate.cfg.Binder.createProperty(Binder.java:1057)
at net.sf.hibernate.cfg.Binder.propertiesFromXML(Binder.java:1050)
how do I define an autoincremented integer in my mapping XML?
thanks and regards
Paul.
|