Clear previously left-over PQresult before calling pg_get_result()