On 8/11/06, Wright, Jim (NIH/CIT) [C] <[EMAIL PROTECTED]> wrote:
Tom, I also did a little experiment to see the order in which each object is inserted by the store method. However the only one that appeared to be inserted was my report object which is the parent of scientist and IOS objects. I was hoping I could at least try putting the current scid value into the scid field of IOS. However IOS inserted but I had no relative idea when it was inserted due to the inability to get the "firing sequence" of the inserts. I don't like to work around the whole idea of ORM but since I cannot change our database I was hoping for a workaround.
Mhmm, references and collections are only inserted if the auto-update property in the corresponding descriptor is set to 'object' (or 'true' which is the older name). If you want to see what is happening, configure P6Spy (there's a FAQ entry for that) and check the SQL that OJB generates. But in general, it is not such a good idea to use PK fields for FK fields. As I said, the identity of the object will change if you change its reference to point to another object. And ORM tools like OJB depend on the identity. This is what defines the object: different PKs = different objects. Tom --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]