0

访问数据库时出现以下错误,

 SQL Error: 0, SQLState: S1009
 Parameter number 3 is not an OUT parameter

请看下面的代码

CallableStatement callableStatement = 
connection.prepareCall("{call ECommerce_GENAUTO(?,?,?,?)}");  
callableStatement.setString(1, orgId);
callableStatement.setString(2, tempCode);

callableStatement.registerOutParameter(3, Types.VARCHAR);
callableStatement.registerOutParameter(4, Types.INTEGER);               

callableStatement.execute();
setAutoGenrtdCode(callableStatement.getString(3));
setAutoGenrtdStatus(callableStatement.getInt(4));
4

0 回答 0