I have a Java static method defined as a stored proc
When I run it through Spring JdbcTemplate,
JdbcTemplate's createCallableStatememt calls H2 internal org.h2.command.dml.Call.prepare method.
This inturn calls "ResultInterface result = tableFunction.getValueTemplate(session);"
This leads to org.h2.expression.function.table.JavaTableFunction.getValueTemplate call
This leads to org.h2.schema.FunctionAlias.getTableValue
this in turn calls "execute" method
In this method, at line 495, it is invoking the stored procedure with null arguments
Subsequently, when jdbcTemplate calls action.doInCallableStatement(cs) , the java static method stored proc gets executed with actual arguments!!
Then it gets executed again with null arguments for the third time
This is the actual "execute" call from JdbcPreparedStatement clas.
Why does prepare call end up in excute call?