Subject Re: [firebird-support] Stored Procedures using IBPP
Author Helen Borrie
At 05:01 AM 15/01/2008, Hans wrote:
>For a select add a suspend; line
>
>CREATE PROCEDURE TestProc
> RETURNS (five_val INTEGER)
>AS BEGIN
> five_val = 5;
>suspend;
>END;

That's one way, but making the stored proc selectable is overkill for a SP that returns one and only one result record. Selectable SPs are designed for multiple-record output - "datasets" and require a lot more overhead.

Fb returns the output from an executed SP in the output xsqlda. The better solution will be to find out how IBPP wraps the output xsqlvars for executed SPs and read the result directly after execution.

./heLen