On Apr 2, 2009, at 11:07 PM, Gordon Shannon wrote:


That does the trick, awesome!

I do think it would be great if psql had a "stderr" capture in addition to
stdout.

While the recommendations to use script are perfect for the use case of capturing everything, including input, I think it's worth mentioning that there was some discussion not too long ago to give psql better IO redirection capabilities. The suggestion I like was something along the lines of

pagila# \o > stdout.txt 2> stderr.txt

as the meaning of that should be immediately obvious to most *nix users and would also allow

pagila# \o > allout.txt 2>&

and this would default to stdout for backwards compatibility (and simplicity)

pagila# \o stdout.txt

Erik Jones, Database Administrator
Engine Yard
Support, Scalability, Reliability
866.518.9273 x 260
Location: US/Pacific
IRC: mage2k






--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to