Re: Cast on character columns in views - Mailing list pgsql-sql

From Tom Lane
Subject Re: Cast on character columns in views
Date
Msg-id 25051.1188918188@sss.pgh.pa.us
Whole thread Raw
In response to Re: Cast on character columns in views  (Richard Broersma Jr <rabroersma@yahoo.com>)
List pgsql-sql
Richard Broersma Jr <rabroersma@yahoo.com> writes:
> --- "Luiz K. Matsumura" <luiz@planit.com.br> wrote:
>> But when I open a query tool window and do:
>> SELECT * FROM view1;
>> Now, again type1 column returns as bpchar.

> This might be a good question to ask on the PGAdmin mailing list or even try using the latest
> version of PGAdmin.  Perhaps this is something that PGAdmin is doing rather than postgresql.

The seeming ordering dependency certainly sounds like it might be a
client-side bug --- something failing to keep straight which typmod goes
with which column, maybe?

There are some backend-side issues with simply not being able to tell
the difference between null::bpchar and null::char(3) ... but for
any given view definition, it's pretty hard to see how the order of
selecting the columns would matter.  A client-side bug seems a bit
more likely.
        regards, tom lane


pgsql-sql by date:

Previous
From: Bryce Nesbitt
Date:
Subject: Re: Partial index on boolean - Sometimes fails to index scan
Next
From: PostgreSQL Admin
Date:
Subject: Trigger to change different row in same table