ECPGstatus documentation

From: Edmund Bacon <ebacon(at)onesystem(dot)com>
To: pgsql-interfaces(at)postgresql(dot)org
Subject: ECPGstatus documentation
Date: 2005-01-06 17:39:57
Message-ID: 41DD77ED.1030306@onesystem.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

I've just spent a half hour or so trying to figure out why a call to
ECPGstatus() was complaining about the wrong number of arguments. The
documentation states:

ECPGstatus() returns true if you are connected to a database and false
if not.

However, digging through the archives, I found the following from Jan 7,
2000:

> ECPGstatus() seems to have changed to ECPGstatus (int, const char);
> What exactly am I supposed to pass to this function?

The first argument is the line-number (i.e. __LINE__). The second is the
connection name. If you do not have different connections you can use
NULL as connection name or just use "CURRENT".

Michael

So, could either the documentation be updated to reflect the correct
parameters to ECPGstatus() or perhaps
src/interfaces/ecpg/preproc/preproc.y can be patched to Do The Right
Thing? If I had any experience with bison/yacc/lex/flex/whatever, I'd
take a look at it, but as I don't ... :-(

Thanks.

--
Edmund Bacon <ebacon(at)onesystem(dot)com>

Responses

Browse pgsql-interfaces by date

  From Date Subject
Next Message Bruce Momjian 2005-01-07 05:44:06 Re: ECPGstatus documentation
Previous Message Stephen Birch 2005-01-05 23:16:07 Re: [HACKERS] Re: ECPG documentation