pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Joe Conway <mail@joeconway.com>
To: mailreg@numerixtechnology.de
Cc: pgsql-sql@postgresql.org
Subject: Re: psql -F <TAB>
Date: Thu, 16 Nov 2006 04:37:02 -0800
Message-ID: <455C5B6E.1070403@joeconway.com> (raw)
In-Reply-To: <455C54FE.5090902@numerixtechnology.de>
References: <455C4918.4020604@numerixtechnology.de>
	<20061116115812.GB19298@alvh.no-ip.org>
	<455C54FE.5090902@numerixtechnology.de>

T E Schmitz wrote:
> Alvaro Herrera wrote:
> 
>> T E Schmitz wrote:
>>
>>> I have written a shell script to export data:
>>>
>>> psql -A -t -U $DBUSER -d $DB -c "$QUERY" -F ' '
>>>
>>> Currently, I am using spaces as field separator but what I really 
>>> want is tabs.
>>>
>>> How can I specify a TAB character with the -F option?

> Sorry for having gone off-topic. I was just hoping something like \t 
> could be passed, too.
> 

Try:
    psql -A -t -U $DBUSER -d $DB -c "$QUERY" -F $'\t'

see:
    man bash

HTH,

Joe



view thread (6+ messages)  latest in thread

Message-ID: <455C5B6E.1070403@joeconway.com>
Permalink:  ../455C5B6E.1070403@joeconway.com/
Also on:    postgresql.org/message-id/455C5B6E.1070403@joeconway.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: mail@joeconway.com, mailreg@numerixtechnology.de
  Subject: Re: psql -F <TAB>
  In-Reply-To: <455C5B6E.1070403@joeconway.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox