[Teneo] PersistenceOptions.JOIN_COLUMN_NAMING_STRATEGY [message #608761] |
Tue, 17 July 2007 11:19 |
Roman Bliznets Messages: 75 Registered: July 2009 |
Member |
|
|
Hello, I'm updated teneo version to 0.8.0.v200707121518,
I want to use new version in order to correct
https://bugs.eclipse.org/bugs/show_bug.cgi?id=185717 bug.
Casused exception:
org.hibernate.MappingException: Foreign key
(FKF8C83C375882C2E:dtsadd_paymentdescription [dtsadditionalpaymentst_id]))
must have same number of columns as the referenced primary key
(dtsadditionalpaymentstype
[dtsadditionalpaymentst_id,dtsadditionalpayments_idx])
at org.hibernate.mapping.ForeignKey.alignColumns(ForeignKey.jav a:90)
at org.hibernate.mapping.ForeignKey.alignColumns(ForeignKey.jav a:73)
....
Should I use some persistence options?
I tried to use PersistenceOptions.JOIN_COLUMN_NAMING_STRATEGY with "unique"
options, but it was useless.
code:
....
final Properties persisence=new Properties();
persisence.put(PersistenceOptions.JOIN_TABLE_NAMING_STRATEGY , "ejb3");
persisence.put(PersistenceOptions.MAXIMUM_SQL_NAME_LENGTH, "25");
persisence.put(PersistenceOptions.INHERITANCE_MAPPING, "JOINED");
// persisence.put(PersistenceOptions.PERSISTENCE_XML , "persistence.xml");
// used earlier
persisence.put(PersistenceOptions.JOIN_COLUMN_NAMING_STRATEG Y, "unique");
hbds.setPersistenceProperties(persisence);
I used to use persistence mapping file, but now it doesn't help.What wrong?
|
|
|
Powered by
FUDForum. Page generated in 0.02899 seconds