Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id B1D87475498 for ; Wed, 7 Aug 2002 11:01:09 -0400 (EDT) Received: from mta4.snet.net (mta4.snet.net [204.60.203.76]) by postgresql.org (Postfix) with ESMTP id 0000B475461 for ; Wed, 7 Aug 2002 11:01:08 -0400 (EDT) Received: from pop.snet.net (pop.snet.net [204.60.203.72]) by mta4.snet.net (8.12.3/8.12.3/SNET-mx-1.2/D-1.1.1.1/O-1.1.1.1) with ESMTP id g77F10IN017314 for ; Wed, 7 Aug 2002 11:01:00 -0400 (EDT) X-Originating-IP: [64.252.95.167] X-SBCIS-MTA: [pop.snet.net] Received: from [192.168.1.83] (167.95.252.64.snet.net [64.252.95.167]) by pop.snet.net (8.12.3/8.12.3/SNET-pop-1.2/D-1.1.1.1/O-1.1.1.1) with ESMTP id g77F17T0014822 for ; Wed, 7 Aug 2002 11:01:11 -0400 (EDT) Subject: Re: running psql in a cron job From: Wei Weng To: pgsql-sql@postgresql.org In-Reply-To: <1028731885.30770.2.camel@Monet> References: <1028731885.30770.2.camel@Monet> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Ximian Evolution 1.0.8 Date: 07 Aug 2002 11:01:09 -0400 Message-Id: <1028732473.30770.4.camel@Monet> Mime-Version: 1.0 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200208/133 X-Sequence-Number: 8979 never mind. a quick search in the mailing list archive solved the problem. :) Just use PGPASSWORD=my_pass psql -c "VACUUM ANALYZE" -d my_data -U my_user On Wed, 2002-08-07 at 10:51, Wei Weng wrote: > My database has "local all password" as its HBA control. > > Is there anyway to manipulate psql so that I can somehow put the > password also inside the command line so that I can run psql in a cron > job? (such as psql -c "VACUUM ANALYZE" -d my_data -U my_user) > > Thanks > > -- > Wei Weng > Network Software Engineer > KenCast Inc. > > > > ---------------------------(end of broadcast)--------------------------- > TIP 6: Have you searched our list archives? > > http://archives.postgresql.org > -- Wei Weng Network Software Engineer KenCast Inc.