edwbear1976a
asked on
right URL for accessing AS400 with Java
Hi there,
I have tried this before on the JavaChannel with no answers for the right URL, I'm developing a java programm that access AS400 database, I got the right driver for that (JTOPEN), but I'm not sure if the URL 's got enough parameters(or Wheather they are right or not)
to acces the AS400 /db2 database
this is my subUrl:
String subUrl = "//"+Server+"/"+Database + ";Uid="+ strLoginId +";Pwd="+strPassword+";pro mpt=false; errors=ful l" ;
String driver="com.ibm.as400.acce ss.AS400JD BCDriver";
String protocol="jdbc:as400:";
String url=protocol+ subUrl ;
I have tried this before on the JavaChannel with no answers for the right URL, I'm developing a java programm that access AS400 database, I got the right driver for that (JTOPEN), but I'm not sure if the URL 's got enough parameters(or Wheather they are right or not)
to acces the AS400 /db2 database
this is my subUrl:
String subUrl = "//"+Server+"/"+Database + ";Uid="+ strLoginId +";Pwd="+strPassword+";pro
String driver="com.ibm.as400.acce
String protocol="jdbc:as400:";
String url=protocol+ subUrl ;
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
well I just used your way to connect and at least I got a error that tells me something
try {
DriverManager.registerDriv
conn = DriverManager.getConnectio
DatabaseMetaData dbMetaData = conn.getMetaData();
conn.close();
}
catch (SQLException e){System.out.println(e.ge
catch (ClassNotFoundException e){System.out.println(e.ge
return conn;
--------------------------
And I get this error
**************************
C:\jakarta-tomcat-5.0.28\w
DriverManager.registerDriv
^
**************************
I got the JTOPEN jar files in my classpath
%classpath%;C:\WINNT\java\
and When I use the NetBeans IDE I added the JTOPEN FILES to my "libraries" so I got the fullpath completed
jt400.jar:
com
ibm
as400
access
as400JDBCDRIVER.class
but even on NetBeans I got the same error "package doesn't exist"
I know that there must be something really silly that I'm missing like adding at the top anything like an import stament or something... should I use Upercase for that package name?