JDBC / Oracle / JAVA - Problem compiling
Date: Tue, 01 Jun 1999 10:06:14 -0400
Message-ID: <3753E8D6.61302E1A_at_mrsl.com>
I am trying to compile a JAVA application which registers the Oracle JDBC driver and gets a compile error "Class oracle.jdbc.driver.OracleDriver not found in type declaration. DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver())"
I thought it was a classpath problem, but I have tried everything I can think of with that including using the -c option on JAVAC and giving it the path there, copying the dbjava_classes111.zip to my working directory, playing with the classpath setting.
The program compiles fine on WINNT.
Here is the code:
import java.sql.*;
class demo
{
public static void main (String args{}) throws SQLException {
DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver()); // This gets the compiler error and it stops here Connection conn = DriverManager.getConnection( "jdbc:oracle:thin:_at_xien01:1526:xiph", "scott", "tiger"); Statement stmt = conn.createStatement(); ResultSet rset = stmt.executeQuery("select ENAME from EMP"); while (rset.next) System.out.println(rset.getString(1));}
}
Any ideas? Thanks. Teri (vokus_at_mrsl.com) Received on Tue Jun 01 1999 - 16:06:14 CEST