This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes JDBC and the fly likes java.lang.UnsatisfiedLinkError: do_open Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "java.lang.UnsatisfiedLinkError: do_open" Watch "java.lang.UnsatisfiedLinkError: do_open" New topic
Author

java.lang.UnsatisfiedLinkError: do_open

Parvinder Arora
Greenhorn

Joined: Aug 14, 2001
Posts: 3
Hi all ,
I am getting the following exception while connecting a sample application using JDBC-OCI driver

Exception in thread "main" java.lang.UnsatisfiedLinkError: do_open
at oracle.jdbc.oci8.OCIDBAccess.do_open(Native Method)
at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java:309)
at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:198)
at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:251)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:224)
at java.sql.DriverManager.getConnection(DriverManager.java:517)
at java.sql.DriverManager.getConnection(DriverManager.java:177)
at Employee.main(Employee.java:28)

I have set the LD_LIBRARY_PATH containing the ocijdbc8.dll and classes12.zip is also in the CLASSPATH

Any clues as to why is this error ?

Thanks & Regards
~Parvinder
Robert Brunner
Ranch Hand

Joined: Jul 18, 2001
Posts: 49
Show me th code! (OK bad Jerry McGuire reference).
Seriously, problems are easiest to diagnose when you include some code.
R
Originally posted by Parvinder Arora:
Hi all ,
I am getting the following exception while connecting a sample application using JDBC-OCI driver

Exception in thread "main" java.lang.UnsatisfiedLinkError: do_open
at oracle.jdbc.oci8.OCIDBAccess.do_open(Native Method)
at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java:309)
at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:198)
at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:251)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:224)
at java.sql.DriverManager.getConnection(DriverManager.java:517)
at java.sql.DriverManager.getConnection(DriverManager.java:177)
at Employee.main(Employee.java:28)

I have set the LD_LIBRARY_PATH containing the ocijdbc8.dll and classes12.zip is also in the CLASSPATH

Any clues as to why is this error ?

Thanks & Regards
~Parvinder

Parvinder Arora
Greenhorn

Joined: Aug 14, 2001
Posts: 3
Hi,
The example is very simple
Following is the code

import java.sql.*;
class Employee
{
public static void main (String args [])
throws SQLException
{
DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
String url = "jdbcracleci8:@(description=(address_list=(address=(protocol=tcp)(port=1521)(host=192.168.5.115)))(connect_data=(sid=orcl1)))";
System.out.println(url);
Connection conn =
DriverManager.getConnection (url, "path", "path");
Statement stmt = conn.createStatement ();
ResultSet rset = stmt.executeQuery ("select primary_email from member");
while (rset.next ())
System.out.println (rset.getString (1));
rset.close();
stmt.close();
conn.close();
}
}
The above code executes fine if the driver is a thin driver but doesnt executes using the oci driver

Originally posted by Robert Brunner:
Show me th code! (OK bad Jerry McGuire reference).
Seriously, problems are easiest to diagnose when you include some code.
R

 
wood burning stoves
 
subject: java.lang.UnsatisfiedLinkError: do_open