Subject | Odp: [firebird-support] Using PSQL as a function ? |
---|---|
Author | liviuslivius@poczta.onet.pl |
Post date | 2014-04-17T14:32:02Z |
Hi,
You must select from somewhere
E.g. use
Select c.valc
,(Select p.val from myproc(123))
From sometable
Regards,
Karol Bieniaszewski
You must select from somewhere
E.g. use
Select c.valc
,(Select p.val from myproc(123))
From sometable
Regards,
Karol Bieniaszewski
----- Reply message -----
Od: "Scott Morgan" <blumf@...>
Do: <firebird-support@yahoogroups.com>
Temat: [firebird-support] Using PSQL as a function?
Data: czw., kwi 17, 2014 16:22
Od: "Scott Morgan" <blumf@...>
Do: <firebird-support@yahoogroups.com>
Temat: [firebird-support] Using PSQL as a function?
Data: czw., kwi 17, 2014 16:22
I checked the FB Book but can't see anything obvious.
Is it possible to use PSQL procedures as functions in SQL? Assuming the
procedure only returns one value, and it's type matches as required,
something like:
SELECT VAL, MY_PSQL_PROC(VAL) FROM SOME_TABLE;
or
SELECT * FROM SOME_TABLE WHERE VAL = MY_PSQL_PROC(123);
It seems like a useful feature but the only way to do that currently is
via external C modules.
Scott