Re: ECPGstatus documentation

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Edmund Bacon <ebacon(at)onesystem(dot)com>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: ECPGstatus documentation
Date: 2005-01-07 05:44:06
Message-ID: 200501070544.j075i6p01311@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces


OK, fixed, patch applied and attached. Are there any other ecpg
documentation additions needed?

---------------------------------------------------------------------------

Edmund Bacon wrote:
> 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>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

Attachment Content-Type Size
unknown_filename text/plain 981 bytes

In response to

Browse pgsql-interfaces by date

  From Date Subject
Next Message Frost, Mr. Michael (contractor) 2005-01-12 16:04:24 ECPG and CURSOR declaration
Previous Message Edmund Bacon 2005-01-06 17:39:57 ECPGstatus documentation