Subject Re: [ib-support] Pls, help! What's wrong with this storedprocedure?
Author Helen Borrie
At 09:54 AM 11-05-02 -0600, Todd Brasseur wrote:
>I don't see how your procedure returns anything. There is no 'suspend'.

Suspend is for outputting rows for a selectable stored procedure. It isn't
required for a SP that simply returns output parameters.

regards,
Helen

Andrew Guts wrote:

> >>>set term ^ ;
> >>>create procedure AddRepForm (NAME VARCHAR(80)) RETURNS (ID INTEGER)
> >>>as
> >>> DECLARE VARIABLE NewID integer;
> >>>begin
> >>> NewID = GEN_ID(G_RFORM_ID, 1);
> >>> insert into RepForms (ID, Name) VALUES (:NewID, :Name);
> >>> ID = NewID;
> >>>end^
> >>>set term ; ^

All for Open and Open for All
Firebird Open SQL Database · http://firebirdsql.org ·
http://users.tpg.com.au/helebor/
_______________________________________________________