Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to validate whether is ResultSet is null or not

807591Mar 14 2008 — edited Mar 19 2008
Hi Friends,

i faced one problems like

ResultSet rs="select * from sample";

----Here i want to validate whether rs is null or not(How to validate for ResultSet)

while(rs.next())
{
System.out.println(rs.getString(1));
}


Please tell me anyone

cheers
Viji
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 16 2008
Added on Mar 14 2008
8 comments
1,074 views