hi,
here is the skeleton of the code:
//declarations earlier in an include file
//...
try{
Class.forName(driver);
conn = DriverManager.getConnection(url, username, password);
String query = "select ...";
statement = conn.createStatement();
rs = statement.executeQuery(query);
//bla-bla, i don't use conn here
}catch(ClassNotFoundException cnfe){
System.err.println("..." + cnfe);
}catch(SQLException sqle){
System.err.println("..." + sqle);
}finally{
conn.close();
}
And in the finally clause comes the NPE.
I thought it may be something misterious with was's connection pooling cause while i wrote and
tested the app with
tomcat it was ok.
Actually as i commented out the conn.close()
it worked welll.
Can u explain this to me pls?I am really interested. THX a lot.
Gergo