Hello,
I'd like to know what's needed to accomplish the mapping for an <element> that uses a UserType.
Thanks in advance.
Randall Schulz
Hibernate version:
3.1 (rc3)
Mapping documents:
Code:
<component name='extra' ... >
<set name='flags' table='EXTRA_FLAGS'>
<key column='HID'/>
<element type='boolean'/>
</set>
...
<map name='numberEntries' table='EXTRA_NUMBERS'>
<key column='HID'/>
<map-key column='NUMBER_NAME' type='string'/>
<element
column='NUMBER_VALUES'
type='MultiNumberUserType'
/>
</map>
</component>
Code between sessionFactory.openSession() and session.close():n/a
Full stack trace of any exception that occurs:Code:
Dec 2, 2005 10:33:23 PM org.hibernate.tool.hbm2ddl.SchemaExport main
SEVERE: Error creating schema
org.hibernate.MappingException: Could not determine type for: MultiNumberUserType, for columns: [org.hibernate.mapping.Column(NUMBER_VALUES)]
at org.hibernate.mapping.SimpleValue.getType(SimpleValue.java:266)
at org.hibernate.mapping.Column.getSqlTypeCode(Column.java:137)
at org.hibernate.mapping.Column.getSqlType(Column.java:181)
at org.hibernate.mapping.Table.sqlCreateString(Table.java:349)
at org.hibernate.cfg.Configuration.generateSchemaCreationScript(Configuration.java:737)
at org.hibernate.tool.hbm2ddl.SchemaExport.<init>(SchemaExport.java:97)
at org.hibernate.tool.hbm2ddl.SchemaExport.<init>(SchemaExport.java:64)
at org.hibernate.tool.hbm2ddl.SchemaExport.main(SchemaExport.java:377)
Name and version of the database you are using:
MySQL 5.0
The generated SQL (show_sql=true):
None so far...