From: Wes B. <we...@ca...> - 2004-06-05 16:34:28
|
I got both copies you sent, but sometimes SourceForge lists are slow. Specifically for primary key mappings there is an extension you can use in your .jdo file. <class name="MyPersistentClass"> <extension vendor-name="XORM" key="table" value="my_table" /> <extension vendor-name="XORM" key="datastore-identity-type" value="java.lang.Long" /> <!-- fields etc --> </class> Looks like this never made it into the documentation. Anyway, this will basically cast all your primary keys to java.lang.Long, since that is what they look like coming back from the database. Wes fi...@so... wrote: > Sorry if this is a copy: > Did anyone know why objects changes their mapped field type apparently > without reason? > u can try, under mysql if it can matter, to call refresh on an object > with an integer primary key. > Magically it will be casted to java.lang.Long.. > Is this a nice nice spell? > Solving this problem is fundamental to preserve the coherence of > various instances mapping the same data on the datastore... > it' about 6.22 am... zzzz |