Manning's Countdown to 2014
. Use discount code crdotd14 all month for 50% off every deal.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
ResultSet return value for an empty query
Joined: Sep 27, 2002
Feb 20, 2003 05:17:00
When a query is executed and no resutls are found what value is returned to the
. In other words I need to determine if the
What method do I use
Joined: Oct 11, 2000
Feb 20, 2003 05:30:00
After you have obtained a "ResultSet", for example:
Connection dbConn = ... String qry = "SELECT ..." Statement stmt = dbConn.createStatement(); ResultSet rs = stmt.executeQuery(qry);
then if that "ResultSet" is 'empty', the first invocation of the "ResultSet" methos "next()" will return 'false', as in:
rs.next(); // returns 'false' if no "next" row.
Hope this answers your question.
subject: ResultSet return value for an empty query
Not getting resultSet from Prepared statement
JSP what's wrong with following code?
How to handl Null Values from Database
my query is successfully running in database but it is returning empty resultset in my java program
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2013