ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tom Henricksen" <T...@A-t-g.com>
Subject Differences in versions
Date Thu, 25 Oct 2007 15:14:31 GMT
We recently upgraded our application to use iBatis 2.3.0.  We used to
use 2.0.9 and were able to do this:

Condensed example old version

            SqlMapClient client = null; 

            Reader reader = null;

            SqlMapSession mapSession = null;

            reader =
Resources.getResourceAsReader("sqlmaps-config.xml");

            client = SqlMapClientBuilder.buildSqlMapClient(reader);

            mapSession = client.openSession();

            // insert the object

            mapSession.insert(id,parameterObject);

            // look for the object on client before commiting the
session

            client.queryForList(id);

mapSession.commitTransaction();

            mapSession.endTransaction();

            mapSession.close();

            mapSession = null;

 

Once we updated to iBatis 2.3.0 we now have to commit the object before
searching for it

New versrion

mapSession.commitTransaction();

// commit then look back for object

                        client.queryForList(id);

 

If we don't do this with 2.3.0 we get a row level locking error.

com.ibm.db2.jcc.a.SqlException: DB2 SQL error: SQLCODE: -911, SQLSTATE:
40001, SQLERRMC: 68

      at com.ibm.db2.jcc.a.cc.b(cc.java:2828)

      at com.ibm.db2.jcc.b.be.i(be.java:181)

      at com.ibm.db2.jcc.b.be.a(be.java:142)

      at com.ibm.db2.jcc.b.be.a(be.java:33)

 

I am not sure if this was a bug, design change or something else.
Perhaps we have some configuration that we need to change with the new
version?

Thanks,

 

                        

Tom Henricksen
Consultant
Advanced Technologies Group, Inc.


Mime
View raw message