Re: 'FATAL: database "null" does not exist ' when accessing through a

Поиск
Список
Период
Сортировка
От Joeseph Blowseph
Тема Re: 'FATAL: database "null" does not exist ' when accessing through a
Дата
Msg-id BAY101-F71802918C3191E364F52E83190@phx.gbl
обсуждение исходный текст
Ответ на Re: 'FATAL: database "null" does not exist ' when accessing  (Oliver Jowett <oliver@opencloud.com>)
Ответы Re: 'FATAL: database "null" does not exist ' when accessing  (Oliver Jowett <oliver@opencloud.com>)
Список pgsql-jdbc
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/


В списке pgsql-jdbc по дате отправления:

Предыдущее
От: Oliver Jowett
Дата:
Сообщение: Re: 'FATAL: database "null" does not exist ' when accessing
Следующее
От: Oliver Jowett
Дата:
Сообщение: Re: 'FATAL: database "null" does not exist ' when accessing