That would depend on the client you're using. psql can do it either
directly (using \o) or by piping its output: psql -c "select * from
mytable;" mydb > out.txt
If you're using a programming library, I think you're on your own.
Adam Ruth
On Feb 8, 2004, at 10:28 AM, Russ Schneider wrote:
Is
Is there an easy way to pipe a select statement's output to a file?
--
[ Russ Schneider (a.k.a. Sugapablo) ]
[ http://www.sugapablo.com <--music ]
[ http://www.sugapablo.net <--personal ]
[ [EMAIL PROTECTED] <--jabber IM ]
---(end of broadcast)-
On Sun, Feb 08, 2004 at 12:28:21PM -0500, Russ Schneider wrote:
> Is there an easy way to pipe a select statement's output to a file?
In psql, type \? and look at what \o and \g do. They both do it but slightly
differently.
--
Martijn van Oosterhout <[EMAIL PROTECTED]> http://svana.org/klept