Stored Procedure Column Heading
Posted in 1998
I have written a simple stored procedure that is returning multiple rows.
What I am trying to get is a column name for the result set. Is there a way
to do this (I am using Online 7.20) ?
Below is the sample SP:
CREATE PROCEDURE sp_test()
RETURNING CHAR(8), CHAR(8);define xcknum CHAR(8);
define xvoid CHAR(8);
FOREACH
select cknum, vo_id into xcknum, xvoid
from cktable
where vo_id matches '14121*'
RETURN xcknum, xvoid WITH RESUME;
END FOREACH;
END PROCEDURE;
The results are:
(expression) (expression)
147231 14121
147231 14121
I want '(expression)' replaced with a more descriptive term. This seems
like a simple request, but I have been unable to find any documentation.
Any suggestions? Thanks.