Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search archives
  Advanced Search

Re: Unicode UTF-8 table formatting for psql text output


  • From: Roger Leigh <rleigh(at)codelibre(dot)net>
  • To: Andrew Dunstan <andrew(at)dunslane(dot)net>
  • Cc: Greg Stark <gsstark(at)mit(dot)edu>, Peter Eisentraut <peter_e(at)gmx(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
  • Subject: Re: Unicode UTF-8 table formatting for psql text output
  • Date: Sat, 31 Oct 2009 18:14:30 +0000
  • Message-id: <20091031181430.GB5993@codelibre.net> <text/plain>

On Sat, Oct 31, 2009 at 12:25:22PM -0400, Andrew Dunstan wrote:
>
>
> Roger Leigh wrote:
>>
>> Wouldn't it be much simpler all around to add a "csv" output format
>> in addition to the above for this purpose?  Spreadsheets can read
>> it in with no trouble at all.
>
> We've had CSV output since version 8.0.

Really?  The only references I see are in tab-complete.c relating to
COPY.

You can set the field separator to ',' but you can't do a
  \pset format csv
and get CSV with correct quoting, escaping etc AFAICS.  It'll
still break on line wrapping if wrapping is enabled, and with
newlines in the data.

If that would be a useful addition, I can add it.


Regards,
Roger

-- 
  .''`.  Roger Leigh
 : :' :  Debian GNU/Linux             http://people.debian.org/~rleigh/
 `. `'   Printing on GNU/Linux?       http://gutenprint.sourceforge.net/
   `-    GPG Public Key: 0x25BFB848   Please GPG sign your mail.

Attachment: signature.asc
Description: Digital signature



Home | Main Index | Thread Index

Privacy Policy | About PostgreSQL
Copyright © 1996 – 2012 PostgreSQL Global Development Group