--
You received this message because you are subscribed to the Google Groups "firebird-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/firebird-support/516b86af-fe76-7701-19d7-821226b4e6f6%40lawinegevaar.nl.
On 22-03-2021 14:00, Tomasz Kujałowicz wrote:
I have many complicated SPs in my database, which returns multiple combinations of data in output parameters.
I have to frequently clear output parameters (set nulls).
Is there in Firebird any internal function or trick to set nulls for all output parameters of stored procedure?
No there is no such function. You need to try writing your stored procedures in a way that they will naturally assign null or the desired value to all columns for the next fetch, and not rely on having to explicitly null the output columns for each fetch.
[..]
Maybe "suspend" should has parameter which forces set nulls for all output parameters?
No it should definitely not do that. The preservation of values after a SUSPEND is a very useful feature,
consider the use of nested loops where the outer loop populates two output columns, while the nested loop(s) populate the rest of the output columns. In your proposal you would need to have additional local variables to preserve the value, and have the additional burden of having to reassign those values to the output columns after each SUSPEND.
Mark
Please consider such functionality. Maybe
it helps others.
-- Tomasz Kujałowicz tel.: +48 509 155 996 e-mail: tomasz.k...@gmail.com