Hi

I have a problem with the next code:

        JDO jdo = null;
        Database db = null;

        try{
                jdo = new JDO();
                jdo.setLogWriter( null );
                jdo.setClassLoader( getClass().getClassLoader() );


jdo.setConfiguration( getClass().getResource( Constants.DATABASE_FILE ).toSt
ring() );
                jdo.setDatabaseName( Constants.DATABASE_NAME );

                db = jdo.getDatabase();
            db.setAutoStore(true);
            db.begin();

            String laQuery =
                "SELECT user FROM com.qarana.databaseAccess.User user WHERE
user.id = 81 ";

            Vector resultVector = new Vector();
                Query queryObject = null;
                QueryResults  results = null;

                queryObject = db.getOQLQuery(laQuery);
                results = queryObject.execute();
                User anUser = (User)  results.nextElement();
                anUser.setEmail("[EMAIL PROTECTED]");


                db.commit();

        }catch(Exception exc){
                exc.printStackTrace();
        }


This code is correctly using a connection pool with an Oracle 8.1.6 Database
but if I change the database in connection pool to other instalation with
another Oracle 8.1.6, in db.commit() I have a TransactionAbortedException

the message is:
 Transaction aborted: Object of type com.qarana.databaseAccess.User with
identity 80 has been modified by a concurrent transaction

I don't understand because the change in connectionPool for use another
database
(but the same schemas) produce an exception. I only change
weblogic.properties
the pool definition (obiously, I work with weblogic)


Sorry for my english, and thanks

Fran.

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to