Hi Antonio,
sorry i have overlook your mail.
Could you post your stack trace too?
How does the Sitio class look like?
Which version of OJB do you use?
regards,
Armin
> > public Application()
>> {
> > Implementation odmg = OJB.getInstance();
> > Database db = odmg.newDatabase();
> > try {
> > db.open("ServidorPersistente/OJB/repository.xml",
> >Database.OPEN_READ_WRITE);
> > } catch (ODMGException ex) {
> > }
> >
> > // create an object
> > newSitio(1);
> > // create the same object - fails on commit and then fails on
> >catch/abort
> > newSitio(1);
> > // create a different object - fails, does not create the
object...
> > newSitio(2);
> > }
> >
> > private void newSitio(int value) {
> > Implementation odmg = OJB.getInstance();
> > Transaction tx = odmg.newTransaction();
> > try {
> > ISitio sitio = null;
> > tx.begin();
> > sitio = new Sitio(value);
> > tx.lock(sitio, tx.WRITE);
> > tx.commit();
> > } catch (Exception ex) {
> > try {
> > tx.abort();
> > } catch (Exception exx) {
> > }
> > }
> > }
> >
> > public static void main(String [] args) {
> > Application app = new Application();
> > }
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>