Thread: [GENERAL] Question programming in C, PGresult *

[GENERAL] Question programming in C, PGresult *

From
"Agape"
Date:
Hi.
 
I have a question regarding programming in C and postgreSQL.
 
Is there any way that I can save few results to one PGresult * ??
 
Like this
------------------------
BEGIN;
DECLARE portal1 CURSOR FOR select * from item where item = 'aa';
DECLARE portal2 CURSOR FOR select * from item where item = 'bb';
DECLARE portal3 CURSOR FOR select * from item where item = 'cc';
 
res = PQexec(conn,"FETCH ALL in portal*");  // Like this
END;
------------------------
I really need this function.
I'm a C programmer but not a expert.
If anyone know how to do this in C...
Please let me know..
 
Thanks in advence.