Problem is that I need to explicitly set the id. I'm defining the test data in and the relationships in an xml file.
For example: <account id="1" .../> <person accountId="1" .../> I need to know the id's so that I can assign them. Otherwise, I could try resetting the sequences, but that would make things a little more messy, programatically. I would rather bypass the sequence manager. I'm going to try the clearCache method mentioned previously, and post my results. Thanks for the suggestions, Dave >-----Original Message----- >From: Jin Bal [mailto:[EMAIL PROTECTED] >Sent: Friday, September 26, 2003 9:51 AM >To: OJB Users List >Subject: Re: storing a new object fails > > >try leaving the PK empty - I thnk that OJB works out whether >its a insert or update by the presence of this field > >There may be a way to force an insert but I can't remember it right now > >Jin >----- Original Message ----- >From: "Durham David Contr 805 CSPTS/SCBE" <[EMAIL PROTECTED]> >To: <[EMAIL PROTECTED]> >Sent: Friday, September 26, 2003 3:49 PM >Subject: storing a new object fails > > >I'm writing a routine that clears out a db and reloads a >defined test data set. I'm trying to insert new objects but >sometimes, not always, OJB will execute an update statement >instead of an insert. I'm explicitly setting the id pk's and >bypassing the sequencemanager, so I figure that has something >to do with it, but I can't explain the discrepancy. Can >anyone point me to the likely cause of this? > >Thanks, > > >Dave > > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]