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

From Pavel Stehule
Subject Re: csv format for psql
Date
Msg-id CAFj8pRDWQELCDmwUBiXY+QuGH7bNmC--q97YXoWb_ra_5S5xWg@mail.gmail.com
Whole thread Raw
In response to Re: csv format for psql  ("David G. Johnston" <david.g.johnston@gmail.com>)
List pgsql-hackers


2018-03-30 0:15 GMT+02:00 David G. Johnston <david.g.johnston@gmail.com>:
On Thu, Mar 29, 2018 at 7:30 AM, Daniel Verite <daniel@manitou-mail.org> wrote:
Personally I think the benefit of sharing fieldsep is not worth these
problems, but I'm waiting for the discussion to continue with
more opinions.

​Apologies in advance if I mis-represent someone's position.​

​It seems like having a dedicated option is the consensus opinion.  Daniel (the original author) and I both prefer it, Pavel will accept it.  Fabien​ is opposed.

Peter E. was opposed, wanting to leverage both fieldsep and recordsep, but hasn't chimed in recently.  His opinion at this point might push this over the edge since he is also a committer.

I would probably suggest maybe just calling it "\pset separator" to match the "S" in "cSv" and not have any name overlap with the fieldsep variable used with unaligned mode.  The user will have to learn anything and being more distinct should help the process.  We would not consult recordsep though the end-of-line choice should be platform dependent.

-1. The difference between fieldsep and separator is not clear, and the relation between separator and csv is not clean too.

fieldsep_csv or csv_fieldsep is not nice, but it is clear.

Regards

Pavel
 

David J.


pgsql-hackers by date:

Previous
From: Paul Guo
Date:
Subject: pg_ugprade test failure on data set with column with default valuewith type bit/varbit
Next
From: Simon Riggs
Date:
Subject: Re: Changing WAL Header to reduce contention during ReserveXLogInsertLocation()