From: Bruce Momjian <maillist@candle.pha.pa.us>
To: lockhart@alumni.caltech.edu
Cc: byronn@insightdist.com
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: Mon, 27 Apr 1998 22:17:55 -0400 (EDT)
Message-ID: <199804280217.WAA01689@candle.pha.pa.us> (raw)
In-Reply-To: <3544A239.FD32AF09@alumni.caltech.edu>
>
> > > > 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.
> > Added to TODO:
> > * Add pg_attribute.atttypmod/Resdom->restypmod to PGresult structure
> > This is a good suggestion.
>
> How do we determine atttypmod for queries like
>
> select '123' || '456';
>
> ?? I might be able to address this with my upcoming type conversion work
> but I don't know if we have enough hooks for this right now...
No way, I think. This would have a atttypmod of -1, which is true
because there is no atttypmod size for this. Once a char()/varchar()
goes into a function, anything can come out.
--
Bruce Momjian | 830 Blythe Avenue
maillist@candle.pha.pa.us | Drexel Hill, Pennsylvania 19026
+ If your life is a hard drive, | (610) 353-9879(w)
+ Christ can be your backup. | (610) 853-3000(h)
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: maillist@candle.pha.pa.us, lockhart@alumni.caltech.edu, byronn@insightdist.com, hannu@trust.ee, daveh@insightdist.com, pgsql-hackers@postgresql.org
Subject: Re: [HACKERS] Re: [INTERFACES] retrieving varchar size
In-Reply-To: <199804280217.WAA01689@candle.pha.pa.us>
* 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