Another Question About How To Use PointBase Dbms
hi all,
another question is about PointBase DataBase.
I use the following source to test it. It comiles correctly,but when i test it with an argument of database name. JVM tell me that ClassDefNotFound.
It seems that JVM can not find "com.pointbase.jdbc.jdbcDriver" as the documentation told.I have set path and i use jdk1.2.2.
Can you tell why?
import java.net.URL;
import java.sql.*;
import java.util.*;
class testdb{
public static void main(String args[]){
String url,user,pwd;
if(args.length==0)
{
System.out.println("Forger Data Source");
System.out.println("Use DB");
System.exit(0);
}
url="jdbc:pointbase:"+args[0];
if(args.length>1){
user=args[1];}
else
{user="";
}
if(args.length>2){
pwd=args[2];}
else
{
pwd="";}
try
{
Class.forName("com.pointbase.jdbc.jdbcDriver");
Connection con=DriverManager.getConnection(url,user,pwd);
DatabaseMetaData dd=con.getMetaData();
System.out.println("Data Source URL:"+dd.getURL());
System.out.println("Driver Name:"+dd.getDriverName());
System.out.println("Driver Version:"+dd.getDriverVersion());
System.out.println("Database Product Name:"+dd.getDatabaseProductName());
System.out.println("Database Product Version:"+dd.getDatabaseProductVersion());
con.close();
}
catch(Exception ex){
System.out.println(ex.getMessage());
ex.printStackTrace();
}
}
}

