Re: csv format for psql - Mailing list pgsql-hackers

From Daniel Verite
Subject Re: csv format for psql
Date
Msg-id 107138b9-74b0-4848-8e32-fedccbf49f8c@manitou-mail.org
Whole thread Raw
In response to Re: csv format for psql  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: csv format for psql
List pgsql-hackers
    Pavel Stehule wrote:

> so we can to have
>
> \pset format xxx
>
> and set of local possibly changed defaults
>
> \pset csv_fieldsep ,
> \pset csv_tuplesonly on
> \pset unaligned_fieldsep |
> \pset unaligned_tuplesonly off

tuples_only (\t) is a single setting that is currently used by all
formats. It makes sense as it is and I don't quite see what we
would gain by "exploding" it.
There's also "footer" that goes in tandem with "tuples_only",
to switch off the footer while keeping the header and title.
Whatever change is considered to "tuples_only", "footer" must
be considered with it.
For the csv format, tuples_only=off is interpreted as "output the header"
and tuples_only=on as "don't output the header". This is consistent
with what other formats do.


Best regards,
--
Daniel Vérité
PostgreSQL-powered mailer: http://www.manitou-mail.org
Twitter: @DanielVerite


pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: [HACKERS] path toward faster partition pruning
Next
From: Erik Rijkers
Date:
Subject: Re: WIP: Covering + unique indexes. (the good and the bad)