Re: psql -F - Mailing list pgsql-sql

From Kazuyuki Maejima
Subject Re: psql -F
Date
Msg-id 455C765D.7030504@oak.ocn.ne.jp
Whole thread Raw
In response to Re: psql -F  (Joe Conway <mail@joeconway.com>)
List pgsql-sql
Joe Conway wrote:
> Try:
>    psql -A -t -U $DBUSER -d $DB -c "$QUERY" -F $'\t'

That's excellent, but please let me post a different way :)
by passing commands from stdin:

#!/bin/sh
cat <<EOT | psql -q -A -t -U $DBUSER -d $DB
\f '\t'
$QUERY
EOT

I think this will work even if your /bin/sh is not bash
(like FreeBSD and NetBSD).

Cheers,
Kazuyuki



pgsql-sql by date:

Previous
From: "Ezequias Rodrigues da Rocha"
Date:
Subject: Apoie o estudo das células tronco
Next
From: "Ezequias Rodrigues da Rocha"
Date:
Subject: Random()