Skip to Main Content

SQL Developer Data Modeler

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

cannot connect to oracle from transformation script (driver not found)

Gell�rt-OracleOct 18 2013 — edited Oct 21 2013

Given the following code in a transformation script:

importPackage(java.sql);

conn = java.sql.DriverManager.getConnection ("jdbc:oracle:thin:@localhost:1521:db1", "ueser", "passw");

stmt = conn.createStatement();

rset = stmt.executeQuery("SELECT * FROM DUAL");

rset.close();

stmt.close();

conn.close();

The error message is:

No suitable driver found for jdbc:oracle:thin:@localhost:1521:db1

I even tried to add the below lines to "Third Party JDBC Drivers", but it did not help.

D:\oracle\product\12.1.0\dbhome\jdbc\lib\ojdbc7.jar

D:\oracle\product\12.1.0\dbhome\jlib\orai18n.jar

Comments

if you look at examples you'll see following statement before getConnectionon...

java.lang.Class.forName ("oracle.jdbc.OracleDriver");

Philip

Gell�rt-Oracle

That line was missing from the second example. However my problem is infrastructure related:

java.lang.Class.forName ("oracle.jdbc.OracleDriver"); --->Wrapped java.lang.ClassNotFoundException: oracle.jdbc.OracleDriver

I used Data Modeler 4.0.0.825. This could be related to the custom java home used by my installation.

The same code works with version "3.3.0.747 jre included"

1 - 2
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Nov 18 2013
Added on Oct 18 2013
2 comments
453 views