Informix Error -694
-694 Too many arguments passed to procedure procedure-name.
More arguments were passed to a procedure than a procedure was declared to accept.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-694 fires when a procedure call passes more arguments than the procedure's declaration accepts — per the official guidance, the direct, only cause.
- A procedure call with more arguments than the procedure's parameter list declares — the direct, only cause.
- The procedure's parameter list narrowed during editing (removing a parameter) without updating every call site to match.
- The wrong (similarly-named) procedure called by mistake, one with a shorter parameter list than the one actually intended.
Solutions / Resolution
- Review the procedure's declared parameter list and remove the extra argument(s) from the
call —
sysprocedures.numargsgives the declared argument count as a quick sanity check:SELECT procname, numargs FROM sysprocedures WHERE procname = 'update_order'; - Confirm the correct procedure is being called, in case a similarly-named one with a shorter parameter list was intended instead.
Examples
The disallowed attempt
CREATE PROCEDURE update_order(p_order_id INT, p_status CHAR(10))
...
END PROCEDURE;
EXECUTE PROCEDURE update_order(42, 'shipped', 'extra');
-- -694: update_order takes 2 arguments, 3 were passed
Corrected
EXECUTE PROCEDURE update_order(42, 'shipped');
Diagnostic Checks
- Count the arguments in the call against the procedure's declared parameter list, querying
sysproceduresif the declaration isn't immediately visible.
Related Errors / Related Topics
- -674 — "Routine routine-name cannot be resolved." A related routine-call error — an incorrect argument count is one of several conditions that error covers, while -694 is specific to passing too many arguments.
Recount the call's arguments against the procedure's actual declared parameter list.