"Tim Barnard" <tbarnard(at)povn(dot)com> writes:
> Is it necessary to call PQclear if a query that
> would normally return tuples fails?
If you got a non-NULL result from PQexec, you'd better PQclear it,
or suffer the consequences (memory leak -> eventual application crash).
regards, tom lane