Michael Meskes <meskes@topsystem.de> writes:
> Does this mean I can read in a complete C array with one call? I mean
> something like this:
> char emp_name[10][10];
> exec sql select name into :emp_name from emp;
As far as I know that works now; or at least, if it doesn't work it's
a limitation of the embedded-SQL interface, and not anything that has
to do with libpq or the fe/be protocol.
A "result" in libpq's terms is the result of a single SQL command.
The result of a successful query, for example, is typically multiple
rows of data. You only need a PQgetResult loop if (a) you send a
query string that contains several commands, or (b) you issue a
query whose answer contains more than one kind of tuple.
regards, tom lane