From: Byron Nikolaidis <byronn@insightdist.com>
To: Bruce Momjian <maillist@candle.pha.pa.us>
Cc: hannu@trust.ee
Cc: daveh@insightdist.com
Cc: pgsql-hackers@postgreSQL.org
Cc: pgsql-interfaces@postgreSQL.org
Subject: Re: [HACKERS] Re: [INTERFACES] retrieving varchar size
Date: Thu, 23 Apr 1998 22:44:07 -0400
Message-ID: <353FFC77.55A58CF5@insightdist.com> (raw)
References: <199804240137.VAA09828@candle.pha.pa.us>
Bruce Momjian wrote:
> > The problem with that theory is this. If the frontend application just
> > executes some random query, such as "select * from table", you really do not
> > know anything about what is coming back. You must rely on the little bit of
> > information the protocol gives you. In the case of Postgres, it gives you
> > the fieldname, datatype, and size for each column in the result.
> > Unfortunately, for varchar and char(n), the size reports -1. This is not
> > very helpful for describing the result set.
> >
> > Your above example works fine (in fact we use that already) when you know the
> > table and column name, as in metadata functions such as SQLColumns() in the
> > ODBC driver.
>
> Yep. We could pass back atttypmod as part of the PGresult. I can add
> that to the TODO list. Would that help?
Yes, that would do it!
Thank you for listening to our ravings on this issue.
Byron
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: byronn@insightdist.com, maillist@candle.pha.pa.us, hannu@trust.ee, daveh@insightdist.com, pgsql-hackers@postgreSQL.org
Subject: Re: [HACKERS] Re: [INTERFACES] retrieving varchar size
In-Reply-To: <353FFC77.55A58CF5@insightdist.com>
* 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