Received: from mx1.organic.com (mx1.organic.com [207.76.139.5]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f94ISqn30397 for ; Thu, 4 Oct 2001 14:28:52 -0400 (EDT) (envelope-from cpesko@organic.com) Received: from vw-sf.organic.com (vw-sf.organic.com [207.76.139.10]) by mx1.organic.com (8.9.3+Sun/8.9.3) with SMTP id LAA09366 for ; Thu, 4 Oct 2001 11:27:25 -0700 (PDT) Received: FROM fwd1-sf.organic.com BY vw-sf.organic.com ; Thu Oct 04 11:28:51 2001 -0700 Received: from goldengate.organic.com ([192.168.5.47]) by fwd1-sf.organic.com (8.9.3+Sun/8.9.3) with ESMTP id LAA20961; Thu, 4 Oct 2001 11:29:03 -0700 (PDT) Received: from cpesko-del-sfo.organic.com (h16.n33.organic.com [192.168.33.16]) by goldengate.organic.com (8.9.3+Sun/8.9.3) with ESMTP id LAA01733; Thu, 4 Oct 2001 11:28:56 -0700 (PDT) Message-Id: <4.3.2.7.2.20011004113541.01dc6d10@mailhost.organic.com> X-Sender: cpesko@mailhost.organic.com X-Mailer: QUALCOMM Windows Eudora Version 4.3.2 Date: Thu, 04 Oct 2001 11:37:16 -0700 To: missive@hotmail.com, pgsql-admin@postgresql.org From: Chris Pesko Subject: Re: complete output to file?? In-Reply-To: <9pg9c5$1b7d$1@news.tht.net> References: <4.3.2.7.2.20011003114642.01dae980@mailhost.organic.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Archive-Number: 200110/45 X-Sequence-Number: 2291 Thank you very much. I will try your suggestions. I'm new to PostgreSQL and I'm very happy with the quick responses I'm getting from the email subscription. It's a great help. When I get better I will return the favors to others in need. At 12:09 AM 10/4/01 +0000, Lee Harr wrote: > > I use \o [file] to get output to a file but it only records the > > command. For example: > > > > \o vac.out > > vacuum verbose analyze; > > > > I end up with one row "VACUUM" in vac.out. I want the entire output > that I > > see on the screen to go to a file. How is this done? > > > > >I am not sure how to do this entirely within psql, but you can always >use the vacuumdb command or the -c flag to psql... > > >vacuumdb --verbose --analyze -d databasename >& output.txt >psql -c 'vacuum verbose analyze' databasename >& output.txt > > >Note that you must redirect both stdout and stderr to your file >in order to see everything. That seems to be why \o is not catching >the output that you want. > > > > > >---------------------------(end of broadcast)--------------------------- >TIP 4: Don't 'kill -9' the postmaster