This error doesn't seem to be related to iBATIS.  See here:

http://www-1.ibm.com/support/docview.wss?uid=swg21208123

Jeff Butler


On 5/9/07, Tom Henricksen <[EMAIL PROTECTED]> wrote:

 We are adding some non iBatis code and trying to tap in to the iBatis
connection for some code analysis purposes.  This works when we run our code
but through builds unit test we get an exception.  Here is some code
examples:



Connection connection = mapSession.getCurrentConnection();



if (connection == null) {

            mapSession.startTransaction();

            startedTransaction = true;

}



            // SAVE SOME things.



            if (startedTransaction) {

                                                connection =
mapSession.getCurrentConnection();

                                                connection.commit();

                                    }



                        } finally {

                                    if (startedTransaction && mapSession
!= null) {

                                                mapSession.endTransaction
();

                                                mapSession.close();

                                                mapSession = null;

                                                connection.close();

                                                connection = null;

                                    }

                        }



This is the exceptions we get from our unit tests:



: com.ibm.db2.jcc.a.SqlException: DB2 SQL error: SQLCODE: -805, SQLSTATE:
51002, SQLERRMC: NULLID.SYSLH203 0X5359534C564C3031  at
com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryWithCallback
(GeneralStatement.java:180)  at
com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryForList
(GeneralStatement.java:118)  at
com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForList(
SqlMapExecutorDelegate.java:610)



I realize this is kind of a kludge.  I am guessing this isn't recommended
use?  Would you suggest getting our own connection outside of iBatis?  Is it
possible to pull the connection string info (username and password, etc) out
of the iBatis connection?



Thanks,

Tom



Reply via email to