I'm a newbie in cloudscape (Java too) and I'm having a problem. I've
followed the tutorial that comes with cloudscape to the letter. Everything
worked as advertised up untill this program:
/*
* Licensed Materials - Property of IBM
*
* (C) Copyright IBM Corp. 2000, 2001
* All Rights Reserved.
*/
import java.sql.*;
public class CreateWorldDB {
public static void main (String[] args) {
try {
Class.forName(" com.ibm.db2j.jd bc.DB2jDriver") .newInstance();
System.out.prin tln("Loaded the Cloudscape JDBC
driver. Hello, World!");
Connection conn =
DriverManager.g etConnection("j dbc:db2j:HelloW orldDB;create=t rue")
;
System.out.prin tln("Created and connected to
database HelloWorldDB");
} catch (Throwable e) {
System.out.prin tln("exception thrown");
e.printStackTra ce();
}
}
}
I run it with "java -Dbd2j.system.ho me=C:\tutorial_ system CreateWorldDB"
And results in:
Loaded the Cloudscape JDBC driver. Hello, World!
exception thrown
java.sql.SQLExc eption: No suitable driver
at java.sql.Driver Manager.getConn ection(Unknown Source)
at java.sql.Driver Manager.getConn ection(Unknown Source)
at CreateWorldDB.m ain(CreateWorld DB.java:18)
What's going on? It can connect with that driver but it can't create/access?
I'm highly confused...
I'm running J2SE/HotSpot VM 1.4.2_03 and cloudscape5.1
Thanks,
Rob
followed the tutorial that comes with cloudscape to the letter. Everything
worked as advertised up untill this program:
/*
* Licensed Materials - Property of IBM
*
* (C) Copyright IBM Corp. 2000, 2001
* All Rights Reserved.
*/
import java.sql.*;
public class CreateWorldDB {
public static void main (String[] args) {
try {
Class.forName(" com.ibm.db2j.jd bc.DB2jDriver") .newInstance();
System.out.prin tln("Loaded the Cloudscape JDBC
driver. Hello, World!");
Connection conn =
DriverManager.g etConnection("j dbc:db2j:HelloW orldDB;create=t rue")
;
System.out.prin tln("Created and connected to
database HelloWorldDB");
} catch (Throwable e) {
System.out.prin tln("exception thrown");
e.printStackTra ce();
}
}
}
I run it with "java -Dbd2j.system.ho me=C:\tutorial_ system CreateWorldDB"
And results in:
Loaded the Cloudscape JDBC driver. Hello, World!
exception thrown
java.sql.SQLExc eption: No suitable driver
at java.sql.Driver Manager.getConn ection(Unknown Source)
at java.sql.Driver Manager.getConn ection(Unknown Source)
at CreateWorldDB.m ain(CreateWorld DB.java:18)
What's going on? It can connect with that driver but it can't create/access?
I'm highly confused...
I'm running J2SE/HotSpot VM 1.4.2_03 and cloudscape5.1
Thanks,
Rob
Comment