On Tue, Nov 06, 2018 at 02:57:15PM +0100, Daniel Verite wrote: > Here's a rebased version following these changes.
Thanks for doing a rebase. First, it seems to me that it is necessary to overcomplicate the interface of psql for that. Most of the other formats don't have their own switch, and it is perfectly possible to use CSV format with just --pset=format=csv. -C could also be useful for other things, say compression. Not reusing fieldsep and creating a new variable looks like the correct way to go, as there is no need to bother about cross-option checks if the format is moved from unaligned to csv and the other way around, especially as the delimiter of CSV needs cannot be larger than one-byte. + pset.popt.topt.fieldSepCsv = pg_strdup(","); Let's store that in a variable instead of hardcoding it. In the regression tests, "col 9" is wanted with a newline? I am still digging into the details of this patch, and I am unfortunately running out of fuel for the day. -- Michael
signature.asc
Description: PGP signature