From: Christoph Haller <ch@rodos.fzk.de>
To: pgsql-interfaces@postgresql.org
Subject: Re: ColumnName and ColumnNumber in libpq (C interface)
Date: Tue, 16 Sep 2003 09:51:59 +0200
Message-ID: <3F66C11E.AE5B7B97@rodos.fzk.de> (raw)
>
> Christoph Haller <ch@rodos.fzk.de> writes:
> >> I thougth running this helloworldish C program:
> >> should print
> >> Bar
> >> 0
> >>
> >> but stdout shows
> >> Bar
> >> -1
> >>
>
> > All names are folded to lowercase, except enclosed in double quotes.
So
> > printf("%d\n",PQfnumber(res,"\"Bar\""));
> > gives you the right result.
>
> I wonder whether this behavior is appropriate for PQfnumber, though.
> It's never been documented ... and certainly should be if we decide
> we should keep it. Comments?
>
> regards, tom lane
>
I'd say it should be left as it is, and documented of course.
I can see a possible ambiguity, if someone is queer enough to
define columns like "bar", "Bar", "BAR", etc. within the same table.
Regards, Christoph
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-interfaces@postgresql.org
Cc: ch@rodos.fzk.de
Subject: Re: ColumnName and ColumnNumber in libpq (C interface)
In-Reply-To: <3F66C11E.AE5B7B97@rodos.fzk.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox