From: | Peter Mount <peter(at)taer(dot)maidstone(dot)gov(dot)uk> |
---|---|
To: | Lam Nguyen <lnguyen(at)osf1(dot)gmu(dot)edu> |
Cc: | pgsql-interfaces(at)postgresql(dot)org |
Subject: | Re: [INTERFACES] newbie to both Java and psql trying jdbc-examples |
Date: | 1998-06-17 07:02:46 |
Message-ID: | Pine.LNX.3.95.980617075601.27478B-100000@taer.maidstone.gov.uk |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-interfaces |
On Wed, 17 Jun 1998, Lam Nguyen wrote:
> Following the directions closely and I still can't get the
> examples going. Any pointers are extremely helpfull, as I am running
> out of FAQs. I am trying to run :
>
> /usr/src/pgsql/postgresql-6.3.2/src/interfaces/jdbc$ java
> -Djdbc.driver=postgresql.Driver example.blobtest jdbc:postgresql:mydb
> mylogin mypassword debug
>
> my pg_hba_conf.sample:
>
> local all password
> host all 127.0.0.1 255.255.255.255 password
Only the host line affects JDBC. Also, you may want to add a host line for
your hosts network address as well, like:
host all 192.168.1.1 255.255.255.255 password
> and the result:
>
> PostgreSQL blobtest v6.3 rev 1
>
> DriverManager.initialize: jdbc.drivers = null
> JDBC DriverManager initialized
> registerDriver:
> driver[className=postgresql.Driver,context=null,postgresql(dot)Driver(at)80c81f9]
> Connecting to Database URL = jdbc:postgresql:mydb
> DriverManager.getConnection("jdbc:postgresql:mydb")
> trying
> driver[className=postgresql.Driver,context=null,postgresql(dot)Driver(at)80c81f9]
> -- listing properties --
> password=mypassword
> Protocol=postgresql
> user=mylogin
> PGDBNAME=mydb
> java.sql.SQLException: User authentication failed
> at postgresql.Connection.<init>(Connection.java:229)
Have you created the user in the database using "create user" ?
--
Peter Mount, peter(at)maidstone(dot)gov(dot)uk
Postgres email to peter(at)taer(dot)maidstone(dot)gov(dot)uk & peter(at)retep(dot)org(dot)uk
Remember, this is my work email, so please CC my home address, as I may
not always have time to reply from work.
From | Date | Subject | |
---|---|---|---|
Next Message | Mariano Herrero | 1998-06-17 10:08:04 | About postgres libraries |
Previous Message | Lam Nguyen | 1998-06-17 05:42:58 | newbie to both Java and psql trying jdbc-examples |