You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ibatis.apache.org by "Clinton Begin (JIRA)" <ib...@incubator.apache.org> on 2005/06/25 06:47:59 UTC

[jira] Closed: (IBATIS-152) NullPointer Exception thrown in GeneralStatement.executeQueryWithCallback when using Log4j

     [ http://issues.apache.org/jira/browse/IBATIS-152?page=all ]
     
Clinton Begin closed IBATIS-152:
--------------------------------

    Fix Version: 2.1.5
     Resolution: Fixed
      Assign To: Clinton Begin

Fixed as described by Sven.  Thanks again Sven!

> NullPointer Exception thrown in GeneralStatement.executeQueryWithCallback when using Log4j
> ------------------------------------------------------------------------------------------
>
>          Key: IBATIS-152
>          URL: http://issues.apache.org/jira/browse/IBATIS-152
>      Project: iBatis for Java
>         Type: Bug
>   Components: SQL Maps
>     Versions: 2.1.0
>  Environment: Windows XP, Java 1.3
>     Reporter: David Winterbottom
>     Assignee: Clinton Begin
>      Fix For: 2.1.5
>  Attachments: PreparedStatementLogProxy_final.java, RefCursor.zip, StatementLogProxy_final.java
>
> Hi,
> I am trying to follow the supplied test for IBATIS-53 (Oracle ref cursors).
> I have found that running the supplied test (number 6) with log4j-1.2.9.jar on 
> the classpath causes a NullPointerException.
> The stack trace and output is:
> DEBUG [main] - Created connection 3235124.
> DEBUG [main] - {conn-100000} Connection
> DEBUG [main] - {pstm-100001} PreparedStatement: { ? = call mis_extract.mgr_case_temp.FindCases }
> DEBUG [main] - {pstm-100001} Parameters: []
> DEBUG [main] - {pstm-100001} Types: []
> DEBUG [main] - {rset-100002} ResultSet
> DEBUG [main] - Returned connection 3235124 to pool.
> com.ibatis.common.jdbc.exception.NestedSQLException:   
> --- The error occurred in com/kinnect/mis/datamodel/sql/CaseToExtract.xml.  
> --- The error occurred while applying a parameter map.  
> --- Check the output.  
> --- Check the output parameters (retrieval of output parameters failed).  
> --- Cause: java.lang.NullPointerException
> Caused by: java.lang.NullPointerException
> 	at com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryWithCallback(GeneralStatement.java:184)
> 	at com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryForObject(GeneralStatement.java:100)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:561)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:536)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl.queryForObject(SqlMapSessionImpl.java:97)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapClientImpl.queryForObject(SqlMapClientImpl.java:69)
> 	at com.kinnect.mis.MISExtract.readCasesToExtract(MISExtract.java:233)
> 	at com.kinnect.mis.MISExtract.main(MISExtract.java:64)
> Caused by: 
> java.lang.NullPointerException
> 	at java.lang.reflect.Method.invoke(Native Method)
> 	at com.ibatis.common.jdbc.logging.ResultSetLogProxy.invoke(ResultSetLogProxy.java:47)
> 	at $Proxy2.close(Unknown Source)
> 	at com.ibatis.sqlmap.engine.execution.SqlExecutor.closeResultSet(SqlExecutor.java:392)
> 	at com.ibatis.sqlmap.engine.execution.SqlExecutor.executeQueryProcedure(SqlExecutor.java:298)
> 	at com.ibatis.sqlmap.engine.mapping.statement.ProcedureStatement.sqlExecuteQuery(ProcedureStatement.java:34)
> 	at com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryWithCallback(GeneralStatement.java:169)
> 	at com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryForObject(GeneralStatement.java:100)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:561)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:536)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl.queryForObject(SqlMapSessionImpl.java:97)
> 	at com.ibatis.sqlmap.engine.impl.SqlMapClientImpl.queryForObject(SqlMapClientImpl.java:69)
> 	at com.kinnect.mis.MISExtract.readCasesToExtract(MISExtract.java:233)
> 	at com.kinnect.mis.MISExtract.main(MISExtract.java:64)
> Is there a known problem with log4j with IBatis ?
> Is this a problem for RefCursors only ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira