for a single command, \g. Example
select * from employees \g '/home/dbadmin/employees.tab'
Note that there isn't a semicolon at the end. '\g' takes
care of that. '\g' will also let you pipe the table output
to other commands........
Thalis A. Kalfigopoulos wrote:
> Depends on how you place the query? I assume you are asking about the psql client, so before the query just do:
> \o output.txt
>
--
P. J. "Josh" Rovero Sonalysts, Inc.
Email: rovero@sonalysts.com www.sonalysts.com 215 Parkway North
Work: (860)326-3671 or 442-4355 Waterford CT 06385
***********************************************************************