>
>
> Hi, my name is Gabriel and I need to read binary data
> from de DB and write it to a file in C. How do I use
> this cursor? Howm do I read the data from the cursor
> after the query is done and write it to C?
>
Use the libpq interface:
PQexec(.., "DECLARE <cursorname> BINARY CURSOR FOR <query>")
PQexec(.., "FETCH ALL IN <cursorname>")
PQgetvalue(.., .., ..)
PQexec(.., "CLOSE <cursorname>")
See the doc on libpq for details.
Regards, Christoph