BUG #9894: SQLError() is not returns SQL_NO_DATA_FOUND - Mailing list pgsql-bugs

From gayathri.annur@gmail.com
Subject BUG #9894: SQLError() is not returns SQL_NO_DATA_FOUND
Date
Msg-id 20140407113645.367.41104@wrigleys.postgresql.org
Whole thread Raw
Responses Re: BUG #9894: SQLError() is not returns SQL_NO_DATA_FOUND  (Michael Paquier <michael.paquier@gmail.com>)
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      9894
Logged by:          Gayathri
Email address:      gayathri.annur@gmail.com
PostgreSQL version: 9.1.1
Operating system:   redhat
Description:

Hi ALL,

SQLError() is not returning SQL_NO_DATA_FOUND after driver upgrade from 7 to
9.

my code looks like

RETCODE rc = SQL_SUCCESS;
while ( rc != SQL_NO_DATA_FOUND)
{
    rc = SQLError(henv, hdbc, hstmt, sqlstate, &nativeerr, errmsg,
                 SQL_MAX_MESSAGE_LENGTH - 1, &actualmsglen);

 }
And whenever I try to access an missing table, I am getting sqlstate as
42P01 and rc as SQL_SUCCESS and it is not coming out of the loop. The same
code worked fine for earlier version.

Please let me know how can I proceed further. Shall I need to handle each
state separately?

Thanks,
Gayathri

pgsql-bugs by date:

Previous
From: Marcin Kamionowski
Date:
Subject: JDBC date before gregorian calendar
Next
From: nk.schjoedt@gmail.com
Date:
Subject: BUG #9895: Duplicate pkey