[jboss-user] [Installation, Configuration & DEPLOYMENT] - Re: [JBoss 4.2.2GA]Problem with PostgreSQL as DefaultDS

klapcio do-not-reply at jboss.com
Thu Jun 26 09:32:13 EDT 2008


"jaikiran" wrote : What does your datasource file look like? And also which jars did you copy to the server/< serverName>/lib folder?
  | 

My postgres-ds.xml looks:

  | <?xml version="1.0" encoding="UTF-8"?>
  | 
  | <!--  Datasource config for Postgres                                      -->
  | 
  | <datasources>
  |   <local-tx-datasource>
  |     <jndi-name>DefaultDS</jndi-name>
  |     <connection-url>jdbc:postgresql://[servername]:[port]/[database name]</connection-url>
  |     <driver-class>org.postgresql.Driver</driver-class>
  |     <user-name>jboss</user-name>
  |     <password>jboss</password>
  |         <!-- sql to call when connection is created.  Can be anything, select 1 is valid for PostgreSQL
  |         <new-connection-sql>select 1</new-connection-sql>
  |         -->
  | 
  |         <!-- sql to call on an existing pooled connection when it is obtained from pool.  Can be anything, select 1 is valid for PostgreSQL
  |         <check-valid-connection-sql>select 1</check-valid-connection-sql>
  |         -->
  | 
  |       <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml -->
  |       <metadata>
  |          <type-mapping>PostgreSQL 8.0</type-mapping>
  |       </metadata>
  |   </local-tx-datasource>
  | 
  | </datasources>
  | 

I copied postgresql-8.1-412.jdbc3.jar into lib directory (I'm using PostgreSQL 8.1.11 on Solaris10)

A DB connection with psql client works fine

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4160866#4160866

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4160866



More information about the jboss-user mailing list