我cmd开个dos窗体后,E:\>java utils.dbping ORACLE sfhc b platform Starting Loading jDriver/Oracle .....**** Success!!! ****You can connect to the database in your app using: java.util.Properties props = new java.util.Properties(); props.put("user", "sfhc"); props.put("password", "b"); java.sql.Driver d = (java.sql.Driver)Class.forName("weblogic.jdbc.oci.Driver") .newInstance(); java.sql.Connection conn = d.connect("jdbc:weblogic:oracle:platform", props); // This mode is superior, especially in serverside classes because // it avoids DriverManager calls are class synchronized, and will // bottleneck any other JDBC in the server, even already-running // connections, because all JDBC drivers use DriverManager.println() // to log info and exceptions, and that call is also class synchronized. // For repeated connecting, a single driver instance can be re-used.**** or **** Class.forName("weblogic.jdbc.oci.Driver").newInstance(); java.sql.Connection conn = Driver.connect("jdbc:weblogic:oracle:platform", "sfhc", "b");**** or **** java.util.Properties props = new java.util.Properties(); props.put("user", "sfhc"); props.put("password", "b"); props.put("server", "platform"); Class.forName("weblogic.jdbc.oci.Driver").newInstance(); java.sql.Connection conn = Driver.connect("jdbc:weblogic:oracle", props); 一切都是OK的啊,怎么到了jbuilder中就不行了啊?
下面有:weblogicoci39.dll,weblogicoxa39.dll两个文件,可是我将这个path加入了,weblogic的路径,加入了jbuilder的路径都不成,why?
说详细一点,加入到JBUILDER的什么路径?应该加入系统的PATH路径。
Starting Loading jDriver/Oracle .....**** Success!!! ****You can connect to the database in your app using: java.util.Properties props = new java.util.Properties();
props.put("user", "sfhc");
props.put("password", "b"); java.sql.Driver d = (java.sql.Driver)Class.forName("weblogic.jdbc.oci.Driver")
.newInstance();
java.sql.Connection conn = d.connect("jdbc:weblogic:oracle:platform", props); // This mode is superior, especially in serverside classes because
// it avoids DriverManager calls are class synchronized, and will
// bottleneck any other JDBC in the server, even already-running
// connections, because all JDBC drivers use DriverManager.println()
// to log info and exceptions, and that call is also class synchronized.
// For repeated connecting, a single driver instance can be re-used.**** or **** Class.forName("weblogic.jdbc.oci.Driver").newInstance();
java.sql.Connection conn =
Driver.connect("jdbc:weblogic:oracle:platform", "sfhc", "b");**** or **** java.util.Properties props = new java.util.Properties();
props.put("user", "sfhc");
props.put("password", "b");
props.put("server", "platform");
Class.forName("weblogic.jdbc.oci.Driver").newInstance();
java.sql.Connection conn =
Driver.connect("jdbc:weblogic:oracle", props);
一切都是OK的啊,怎么到了jbuilder中就不行了啊?