Hi,
I am trying to connect to a db2 database via a jdbc application and
this is the following error I get:
Exception : [IBM][JDBC Driver] CLI0615E Error receiving from socket,
server is not responding. SQLSTATE=08S01
Below is the following code I am using. I did not specify the port
number but even when I try specify it I get the same error.
I did some research and some people are saying that it depens on my
jdbc driver and it's version. but I don't know how to find out the
version.
Any help is greatly appreciated.
Thanks,
Rob
static String driver = "COM.ibm.db2.jdbc.net.DB2Driver";
static String url = "jdbc:db2://servername/database";
static String pw ="username";
static String user="password";
public static void EstablishDBConnection()
{
try
{
Class.forName(driver);
System.out.println("Driver Loaded");
Connection connection = DriverManager.getConnection(url, user,
pw);
}
catch(Exception e){
System.out.println("Exception : " + e.getMessage());
}
}