Igor Korot <ikorot01@gmail.com> writes:
> However it leads to another question - should PQclear set the pointer to NULL?
C doesn't provide any reasonable way to do that. The argument of PQclear
needn't even be an lvalue; for example, if you're not too concerned about
error checking, it's not unreasonable to write
PQclear(PQexec(conn, "some SQL command"));
regards, tom lane