Search Postgresql Archives

Re: libpq confusion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 9/20/2017 6:30 AM, Igor Korot wrote:
Hi, guys,

On Wed, Sep 20, 2017 at 12:20 AM, Allan Harvey
<allan.harvey@xxxxxxxxxxxxxxxxxxx> wrote:
How do I properly check if the record exists from libpq?
Igor,
I use PQntuples() to check the number of ... tuples, for > 0
I was actually curious - isn't it what "PGRES_COMMAND_OK" for?
IIUC, this constant indicates successful query run, but no records was
generated.

Or am I missing something and I will have to check PQntuples()?


a query that returns zero rows is still successful.

-- 
john r pierce, recycling bits in santa cruz

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux