Error codes from ODBC driver

From: dirk(dot)jacobs(at)tuple(dot)be
To: pgsql-odbc(at)postgresql(dot)org
Subject: Error codes from ODBC driver
Date: 2002-03-13 16:50:50
Message-ID: OFCFC49AB1.E0BE7C9C-ON41256B7B.005C3C56@tuple.be
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

version 7.01.00.09

Hi there,

I want to detect if a table already exists or an index already exists but
the driver always returns with SQLState S1000 which is a general error
code.

The correct SQLstates are :

#define SQLSTATE_GENERAL_ERROR "S1000"

#define SQLSTATE_TABLE_EXISTS "S0001"
#define SQLSTATE_TABLE_NOT_FOUND "S0002"
#define SQLSTATE_INDEX_EXISTS "S0011"
#define SQLSTATE_INDEX_NOT_FOUND "S0012"

Any suggestions ?

-Dirk Jacobs

Browse pgsql-odbc by date

  From Date Subject
Next Message Corey W. Gibbs 2002-03-13 18:14:13 Maybe more of a VB question, but here goes
Previous Message Jean-Michel POURE 2002-03-13 16:44:52 Re: Please Help! Trying to connect Foxpro 6.0 to RH postgresql via ODBC