Authentication in batch processing - Mailing list pgsql-admin

From Hal Lynch
Subject Authentication in batch processing
Date
Msg-id 5AAA28B2-5DEA-11D6-8644-0050E490FD5B@cc.usu.edu
Whole thread Raw
Responses Re: Authentication in batch processing  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-admin
I have postgres set up to require usernames and passwords for access.

The following script works just fine in 7.1.2 without manual
intervention.  Using 7.2.1 psql issues a password prompt and
blocks until a password is manually entered.

#######################################
#!/bin/sh

psql mydb <<\__EOD__
mypassword
create table mytable
    (
    ssn        char(9),
    name    char(50)
    );
__EOD__
#######################################

For several years now I have been using scripts like the above
to drop and create 14 databases, and create and populate ~100
tables on a nightly basis.  I need this or something like it
to work.

As always I assume I am doing dumb.

Can someone help?

hal


pgsql-admin by date:

Previous
From: "Peter Darley"
Date:
Subject: Process balancing on smp db server/apache web server
Next
From: Mike Baker
Date:
Subject: Re: ALTER TABLE hangs