Unanswered: Please help me to solve this COM.ibm.db2.jdbc.app.DB2Driver error?
Friends I'm using Rational application developer 7.0 and db2express c. I connected the database in RAD using new data connection wizard. I imported db2jcc.jar file too. I'm using Websphere application server community edition.
But while running the page this error displayed in every page.
ERROR : COM.ibm.db2.jcc.DB2Driver
I built the path too. My coding is as follows
<%@ page contentType="text/html; charset=utf-8" language="java" import="java.sql.*" %>
Connection con = DriverManager.getConnection("jdbc:db2:d1");
username = request.getParameter("username");
query="select * from login where username='"username"'and usertype="usertype"";
take this code as an example Java Program Name for DB2 | db2ude
there are 3 'crititcal' things going on in 1 try/catsch block. Why not not 3 of those blocks:
1 for the class-load
1 for the connect
1 for the query
This makes it more easy to pinpoint the error.