Re: SELECT to an external file - Mailing list pgsql-general

From Devrim GUNDUZ
Subject Re: SELECT to an external file
Date
Msg-id Pine.LNX.4.44.0408242010540.3666-100000@emo.org.tr
Whole thread Raw
In response to SELECT to an external file  (Mário Gamito <gamito@netual.pt>)
List pgsql-general
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


Hi,

On Tue, 24 Aug 2004, [ISO-8859-1] Mário Gamito wrote:

> How can i draw the results of a SELECT in to a file in the filesystem ?

Use \o:

test=# \o testfile
test=# SELECT * from mytable;
test=#

All the output is redirected to testfile.

Regards,
- --
Devrim GUNDUZ
devrim~gunduz.org                devrim.gunduz~linux.org.tr
            http://www.tdmsoft.com
            http://www.gunduz.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQFBK3cJtl86P3SPfQ4RAqXlAJ4rpEmebsqRM5f6eWLX6DKMdlFZ8QCgvzHk
bSMZ2kr9s9brM6U6Bn27jJs=
=CREY
-----END PGP SIGNATURE-----


pgsql-general by date:

Previous
From: Oliver Elphick
Date:
Subject: Re: Dump and Restore
Next
From: Oliver Elphick
Date:
Subject: Re: SELECT to an external file