RPC returns fewer output parameters than registered

SQLState: JZ0SG - An RPC did not return as many output parameters as the application had registered for it.

This error occurs if you call CallableStatement.registerOutParam for more parameters than you have declared as “OUTPUT” parameters in the stored procedure. Make sure that you have declared all of the appropriate parameters as “OUTPUT.” Look at the line of code that reads:

 create procedure yourproc (@p1 int OUTPUT, ...

NoteIf you receive this error while using SQL Anywhere, upgrade to SQL Anywhere version 5.5.04 or later.