Re: SQLSTATE not updated in ecpg program.

From: Michael Meskes <meskes(at)postgresql(dot)org>
To: Ken Jennings <ken_jennings(at)bellsouth(dot)net>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: SQLSTATE not updated in ecpg program.
Date: 2006-12-28 14:25:29
Message-ID: 20061228142529.GA18321@feivel.credativ.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

On Thu, Dec 28, 2006 at 08:07:09AM -0500, Ken Jennings wrote:
> This is an alternate version of the program with debugging where I dump the
> contents of all the useful elements of sqlca. The file output.txt shows the
> output of a couple runs (on 8.2.0):
> http://www.kenjennings.cc/st/prg/ux/test_pgc_new_src.tar.gz

And this is run in a all 8.2 environment? I just tested with 8.2 ecpglib
against 8.1 database and got some useful information:

sqlstate[0] =0
sqlstate[1] =8
sqlstate[2] =0
sqlstate[3] =0
sqlstate[4] =1

Using the 8.1 libs I seem to get a memory overrun:

./testpgc test1234 postgres
...
sqlstate[0] =1
sqlstate[1] =2
sqlstate[2] =3
sqlstate[3] =4

Yes, if I use test12 as db name sqlstate[2] and sqlstate[3] are empty.

Michael
--
Michael Meskes
Email: Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org)
ICQ: 179140304, AIM/Yahoo: michaelmeskes, Jabber: meskes(at)jabber(dot)org
Go SF 49ers! Go Rhein Fire! Use Debian GNU/Linux! Use PostgreSQL!

In response to

Browse pgsql-interfaces by date

  From Date Subject
Next Message ken_jennings 2006-12-28 15:42:07 Re: SQLSTATE not updated in ecpg program.
Previous Message Ken Jennings 2006-12-28 13:07:09 Re: SQLSTATE not updated in ecpg program.