Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » JBoss User »

[JBoss-user] url string for connecting jboss to oracle

Amit Ashok

2003-09-03

Replies:

Hi ,
I am trying for the last 2 days to connect jboss 3.2.1 to oracle 9i using OCI client as thin client is not giving me the required output .
 
I have modified oracle-ds.xml
 
<datasources>
  <local-tx-datasource>
    <jndi-name>CLKS1</jndi-name>
 
<connection-url>jdbc:oracle:oci:@172.17.24.11:1521:CLKS1</connection-url>
 
    <!--
    <connection-url>jdbc:oracle:thin:@172.17.24.172:1521:clks1</connection-url>
 
  -->
    <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>
    <user-name>jb</user-name>
    <password>jb</password>
    <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
  </local-tx-datasource>
 
</datasources>
I have tried oci , oci8 ,oci9 but in all the cases I have been denied connection . in case of oci8 with oracle 8i server I got the following error message
 

        at java.lang.Thread.run(Thread.java:479)
org.jboss.util.NestedSQLException: Could not create connection; - nested throwable: (java.sql.SQLException: Error w
hile trying to retrieve text for error ORA-06401
); - nested throwable: (org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable:
 (java.sql.SQLException: Error while trying to retrieve text for error ORA-06401
))
 
while with oracle 9i and 9i drivers I keep getting
 
 
 
com.niit.cliks.control.common.GeneralFailureException: null; CausedByException is:
        Could not create connection; - nested throwable: (java.sql.SQLException: ORA-06401: NETCMN: invalid driver
designator
); - nested throwable: (org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable:
 (java.sql.SQLException: ORA-06401: NETCMN: invalid driver designator
))
 
 
my url string was 
<connection-url>jdbc:oracle:oci:@172.17.24.172:1521:CLKS1</connection-url>
 
 
 
then i changed the url string to
<connection-url>jdbc:oracle:oci9:@172.17.24.172:1521:CLKS1</connection-url>
the exception changed to 
 
com.niit.cliks.control.common.GeneralFailureException: null; CausedByException is:
        Apparently wrong driver class specified for URL: class: oracle.jdbc.driver.OracleDriver, url: jdbc:oracle:o
ci9:@172.17.24.172:1521:CLKS1; - nested throwable: (org.jboss.resource.JBossResourceException: Apparently wrong dri
ver class specified for URL: class: oracle.jdbc.driver.OracleDriver, url: jdbc:oracle:oci9:@172.17.24.172:1521:CLKS
1)
 
can some one help me .
 
 

----------------------------------------------------------- NOTICE ------------------------------------------------------------

This email and any files transmitted with it are confidential and are solely for the use of the individual or entity to which it is addressed. Any use, distribution, copying or disclosure by any other person is strictly prohibited. If you receive this transmission in error, please notify the sender by reply email and then destroy the message. Opinions, conclusions and other information in this message that do not relate to official business of NIIT shall be understood to be neither given nor endorsed by NIIT. Any information contained in this email, when addressed to NIIT Clients is subject to the terms and conditions in governing client contract.

©2008 junlu.com - Jax Systems, LLC, U.S.A.