Re: Show type in psql SELECT - Mailing list pgsql-hackers

From Greg Stark
Subject Re: Show type in psql SELECT
Date
Msg-id CAM-w4HMTayK74Z7wB32sVjrH8fPR0pnjfHGMb2MvO-3Mu0jLPA@mail.gmail.com
Whole thread Raw
In response to Re: Show type in psql SELECT  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
On Sun, Feb 24, 2013 at 11:14 PM, Peter Eisentraut <peter_e@gmx.net> wrote:
> On Sat, 2013-02-23 at 12:09 +1300, Mike Toews wrote:
>> Has anyone else thought this was a missing feature?
>
> I have.

It never occurred to me before what exactly was missing but I did
regularly have to do CREATE TABLE AS (query...) just to see what types
would result. It does seem like having a way to et psql to print that
info without doing any DDL would be appropriate.

I don't have a clear idea how to format it though. It could be in a
second header row under the column names? Or it could be in a separate
block following or preceding the result set? Or it could be only in \x
mode as a third column in addition to the name and value?

-- 
greg



pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: json generation enhancements
Next
From: Mike Toews
Date:
Subject: Re: Show type in psql SELECT