How can I ignore the output parameters of a stored procedure? I am calling process with another process, such as:
DECLARE @ param1 integer EXEC mystoredprocedure @ in_param_1, @ in_param2_, @ param1 output, - what to do here to ignore the second output Will I type the ultimate ?? I am using T-SQL (MS SQL 2005).
You can only use NULL as the last parameter, and it should work properly - As long as that parameter is not expected for input logic in the proc.
In your case, Proc call as D
exec mystoredproc @ in_param_1, @ in_param2_, @ param1 output, empty
Here is another example that for the same scenario ...
set MyTempProc (@ an int, @ two intimate out, @ three inside out) set @ two = 2 Set @ Tri = 3, go to an end as @one declare @ p1 int, @ p2 int set @ p1 = 1 command mitamprpr@p1, @ p2out, tap print @ p1 print @ p2 < / Code>
Comments
Post a Comment