Subject | Re: [firebird-support] How do I execute a SP that returns a result with IBPP ? |
---|---|
Author | Riste Pejov |
Post date | 2004-05-19T10:12:28Z |
Riste Pejov wrote:
that returns a singleton is that you don't issue a Statement->Fetch();
So this works ok:
st1->Prepare("EXECUTE PROCEDURE NEW_CONN '123.456.789.10'");
st1->Execute();
int conn_id;
st1->Get(1, &conn_id);
No need for RETURNING_VALUES at the end of the statement, like I thought.
(EXECUTE PROCEDURE NEW_CONN '123.456.789.10' RETURNING_VALUES cid)
Accept my apologies for bothering the list.
--
Riste Pejov
Card Management System
National Payment Card
Kuzman Josifovski Pitu br.1
tel:++ 389 2 3293 826
Skopje, MKD
http://www.npk.com.mk
> How do I execute a SP that returns a result with IBPP ?The only difference between a select statement and a stored procedure
>
> the sp is:
>
> create procedure NEW_CONN (
> IP_ADDR varchar(15) character set ASCII)
> returns (
> CONN_ID numeric(18, 0))
>
> whitout a returning value i can execute it like this:
> st1->Prepare("EXECUTE PROCEDURE NEW_CONN '123.456.789.10'");
> st1->Execute();
>
that returns a singleton is that you don't issue a Statement->Fetch();
So this works ok:
st1->Prepare("EXECUTE PROCEDURE NEW_CONN '123.456.789.10'");
st1->Execute();
int conn_id;
st1->Get(1, &conn_id);
No need for RETURNING_VALUES at the end of the statement, like I thought.
(EXECUTE PROCEDURE NEW_CONN '123.456.789.10' RETURNING_VALUES cid)
Accept my apologies for bothering the list.
--
Riste Pejov
Card Management System
National Payment Card
Kuzman Josifovski Pitu br.1
tel:++ 389 2 3293 826
Skopje, MKD
http://www.npk.com.mk