Subject Re: Stored procedures
Author Adam
Hi André,

Yes, you need to use a suspend call to return a value, so any examples
you have found that do not use the suspend call (to output the value)
are wrong.

Suspend basically tells Firebird to output one line with the values
that are currently in the output variables. Do not use suspend if your
stored procedure returns no result. Always use suspend if your stored
procedure returns one or more results.

Be very careful of this. I spend about 3 hours the other day looking
for a bug in some stored procedures I had written. It turned out that
I had forgotten to include the suspend, so the variable that had the
timestamp inside the stored procedure (confirmed by call to
OutputDebugString) was not returning it to the other Stored Procedure.
It is very easy to forget.