Subject | Re: [Firebird-Architect] RFC: Please unify stored procedure execution |
---|---|
Author | Nando Dessena |
Post date | 2004-12-21T09:44:13Z |
Martijn,
It wouldn't work only if a SP had output parameters and you forgot to
put a SUSPEND in, but in that case it's assumed that's your fault. For
all the other cases, it's assumed that a SP that has output parameters
is selectable.
M> btw, I'm looking for a SUSPEND in Database Workbench and use
M> SELECT to "run" the procedure then.
Well the suspend could never be executed anyway, depending on the
program flow. Plus you need to parse the code (if you want to make it
robust, at least - you wouldn't want to catch suspends in comments or
literals by mistake, would you?) and I don't think that's appropriate
for Jaybird. Checking for output parameters is simpler, quicker and
at least equally effective.
Ciao
--
Nando Dessena
http://www.flamerobin.org
>> FWIW you could look for output parameters in the SP declaration andM> Huh? How should that work?
>> use the "select" form if you find any. That's what FlameRobin does.
It wouldn't work only if a SP had output parameters and you forgot to
put a SUSPEND in, but in that case it's assumed that's your fault. For
all the other cases, it's assumed that a SP that has output parameters
is selectable.
M> btw, I'm looking for a SUSPEND in Database Workbench and use
M> SELECT to "run" the procedure then.
Well the suspend could never be executed anyway, depending on the
program flow. Plus you need to parse the code (if you want to make it
robust, at least - you wouldn't want to catch suspends in comments or
literals by mistake, would you?) and I don't think that's appropriate
for Jaybird. Checking for output parameters is simpler, quicker and
at least equally effective.
Ciao
--
Nando Dessena
http://www.flamerobin.org