wood burning stoves 2.0*
The moose likes JDBC and the fly likes ResultSet related query. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "ResultSet related query." Watch "ResultSet related query." New topic
Author

ResultSet related query.

saurabh tyagi
Greenhorn

Joined: Dec 20, 2007
Posts: 1
What i am doing is filling dropdown Menu through ResultSet using
while(rs.next())
{
//html code.using scriptlets
}

but when i am trying to close the Database connection.it gives Null pointer error.

Can any one please tell me the problem???That why it gives that error.
David O'Meara
Rancher

Joined: Mar 06, 2001
Posts: 13459

It gives a Null pointer because you are trying to reference something with a null value. I can't say much more without seeing more code.
P. Jain
Greenhorn

Joined: Jan 03, 2008
Posts: 15
Might be the database object that you created would be null.For further details I have to look in the code what mistake you have done.


SCJP 5.0<br />SCWCD 5.0<br />Preparing for SCDJWS
 
Consider Paul's rocket mass heater.
 
subject: ResultSet related query.