From: Joeseph Blowseph <joseph_blowseph@hotmail.com>
To: oliver@opencloud.com
Cc: pgsql-jdbc@postgresql.org
Subject: Re: 'FATAL: database "null" does not exist ' when accessing through a
Date: Sat, 14 Jan 2006 16:59:05 +0000
Message-ID: <BAY101-F71802918C3191E364F52E83190@phx.gbl> (raw)
In-Reply-To: <43C8DEA8.5020703@opencloud.com>
The datasource construction parameters are stored in a data-sources xml file
like this:
<native-data-source name="PGDS1"
data-source-class="org.postgresql.ds.PGPoolingDataSource"
jndi-name="jdbc/PGPooling"
user="postgres" password="password"
url="jdbc:postgresql://localhost:5432/PGSQL1"/>
...
The program code does a jdni lookup for the DataSource. That means that you
don't have to hard-code connection details into the source. But, as things
stand, I have to hard-code the database name.
>From: Oliver Jowett <oliver@opencloud.com>
>To: Joeseph Blowseph <joseph_blowseph@hotmail.com>
>CC: pgsql-jdbc@postgresql.org
>Subject: Re: [JDBC] 'FATAL: database "null" does not exist ' when accessing
>through a datasource
>Date: Sat, 14 Jan 2006 11:21:12 +0000
>
>Joeseph Blowseph wrote:
>
>>DataSourceClass: org.postgresql.ds.PGSimpleDataSource
>>JNDI Name: jdbc/PGSimple
>>URL: jdbc:postgresql://localhost:5432/PGSQL1
>
>If you're using a DataSource, then the internal JDBC URL to use is
>constructed from the parameters used to configure the datasource
>(setDatabaseName, etc).
>
>I don't know what your container is doing with the "JDBC URL" bit, but
>AFAIK it's not used by the datasource at all.
>
>-O
_________________________________________________________________
The new MSN Search Toolbar now includes Desktop search!
http://toolbar.msn.co.uk/
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: joseph_blowseph@hotmail.com, oliver@opencloud.com
Subject: Re: 'FATAL: database "null" does not exist ' when accessing through a
In-Reply-To: <BAY101-F71802918C3191E364F52E83190@phx.gbl>
References: <43C8DEA8.5020703@opencloud.com> <BAY101-F71802918C3191E364F52E83190@phx.gbl>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox