IBM Websphere 5.0, Oracle JDBC DataSource

Discussion in 'Java' started by Anonymous, Jul 17, 2003.

  1. Anonymous

    Anonymous Guest

    I downloaded Oracle's JDBC driver from
    www.oracle.com

    I have Websphere Application Server 5.0 installed
    on my system (Windows 2000)

    I configured a JDBC Provider with the Oracle JDBC Driver.

    After configuring the JDBC Provider, I configured a DataSource.

    My servlet can lookup the DataSource via JNDI.

    However, an exception occurs when I invoke getConnection()
    on the DataSource object.

    getConnection() throws a java.sqlSQLException

    Where do I specify the JDBC URL?

    I noticed that each DataSource can have "Custom Properties" defined
    via the Admin Console.

    Should I set any Custom Properties?

    Here is the stack trace:

    Error 500: Server caught unhandled exception from servlet [myappservlet]:
    java.sql.SQLException: Invalid Oracle URL specified:
    OracleDataSource.makeURL at
    oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134) at
    oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179) at
    oracle.jdbc.dbaccess.DBError.check_error(DBError.java:1130) at
    oracle.jdbc.pool.OracleDataSource.makeURL(OracleDataSource.java:968) at
    oracle.jdbc.pool.OracleDataSource.getURL(OracleDataSource.java:577) at
    oracle.jdbc.xa.client.OracleXADataSource.getXAConnection(OracleXADataSource.
    java:115) at
    oracle.jdbc.xa.client.OracleXADataSource.getXAConnection(OracleXADataSource.
    java:86) at
    com.ibm.ws.rsadapter.DSConfigurationHelper$1.run(DSConfigurationHelper.java:
    643) at java.security.AccessController.doPrivileged(Native Method) at
    com.ibm.ws.rsadapter.DSConfigurationHelper.getPooledConnection(DSConfigurati
    onHelper.java:638) at
    com.ibm.ws.rsadapter.spi.WSRdbDataSource.getPooledConnection(WSRdbDataSource
    ..java:189) at
    com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl.createManagedConnect
    ion(WSManagedConnectionFactoryImpl.java:503) at
    com.ibm.ejs.j2c.poolmanager.FreePool.createManagedConnectionWithMCWrapper(Fr
    eePool.java:1106) at
    com.ibm.ejs.j2c.poolmanager.FreePool.createOrWaitForConnection(FreePool.java
    :897) at
    com.ibm.ejs.j2c.poolmanager.PoolManager.reserve(PoolManager.java:1065) at
    com.ibm.ejs.j2c.ConnectionManager.allocateMCWrapper(ConnectionManager.java:5
    60) at
    com.ibm.ejs.j2c.ConnectionManager.allocateConnection(ConnectionManager.java:
    374) at
    com.ibm.ws.rsadapter.jdbc.WSJdbcDataSource.getConnection(WSJdbcDataSource.ja
    va:205) at
    com.ibm.ws.rsadapter.jdbc.WSJdbcDataSource.getConnection(WSJdbcDataSource.ja
    va:180)
    at myapplication.Util.getDBConnection(Util.java:95) at
    [...]
     
    Anonymous, Jul 17, 2003
    #1
    1. Advertisements

  2. Anonymous

    Anonymous Guest

    I fixed this problem by setting three "Custom Properties"
    for the DataSource in the Websphere admin console.

    1) URL
    2) user
    3) password

    The URL must be a valid Oracle JDBC URL
     
    Anonymous, Jul 19, 2003
    #2
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.