Having problems with JDBC Driver

From: S Varadarajan <rajan_at_trinel.com>
Date: 2000/05/08
Message-ID: <39176660.3A3A0525_at_trinel.com>#1/1


Hi,

I was trying to use Oracle 8.1.5 with JDK1.2 based app on Linux RH6.2. I first tested
the demo app JdbcCheckup.java and it crashed with thiserror message:

Connecting to the database...Connecting... method unknown (eip = 444a2e6e)
SIGSEGV 11* segmentation violation

    si_signo [11]: SIGSEGV   11*  segmentation violation
    si_errno [0]: Success
    si_code [0]: SI_USER [pid: 0, uid: 0]
        stackpointer=0xbfffeedc

Then I realized that it must be JDK1.1.x complaint and then changed the JDK to 118
version. Then I got this error:

Please enter information to test connection to the database user: sys
password: change_on_install
database (a TNSNAME entry): <entered my database instance> Connecting to the database...Connecting... java.sql.SQLException: ORA-12154: TNS:could not resolve service name

        at oracle.jdbc.oci8.OCIDBAccess.check_error(OCIDBAccess.java)
        at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java)
        at
oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java)
        at

oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java)
        at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java)
        at java.sql.DriverManager.getConnection(DriverManager.java:83)
        at java.sql.DriverManager.getConnection(DriverManager.java:126)
        at JdbcCheckup.main(JdbcCheckup.java:43)

If i use sqlplus and connect to the instance using the environment variable $ORACLE_SID
set to the my database then I am able to connect and do normal queries. Could someone
point out the reason for this?

Thanks in advance.

Rajan Received on Mon May 08 2000 - 00:00:00 CEST

Original text of this message