Title: Null Pointer in iBatis 2.1.5_582

I recently ran into a problem while executing a stored procedure using an inline map in iBatis 2.1.5_582.

Caused by: java.lang.NullPointerException

        at com.ibatis.sqlmap.engine.execution.SqlExecutor.handleResults(SqlExecutor.java:355)

        at com.ibatis.sqlmap.engine.execution.SqlExecutor.executeQueryProcedure(SqlExecutor.java:291)

        at com.ibatis.sqlmap.engine.mapping.statement.ProcedureStatement.sqlExecuteQuery(ProcedureStatement.java:34)

        at com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryWithCallback(GeneralStatement.java:173)

The problem looks to be caused by the callable statement not returning a result set in the executeQueryProcedure method.  The rs variable is set to null and passed into the handleResults() method.  This method attempts to get the Type, and the Null Pointer is thrown. 

This looks like a bug and this code executes normally in iBatis 2.0.9 so I thought I would write a note here and see if anyone else ran into this. 

Thanks.

-Bret

Reply via email to