Hi Rahul,
Geert already answered your question (i.e. "Use
DbResultSet.hasResultRows()), so you're good there.
As an extra tip, instead of using:
------
select.from(TABLE_BOOKED_ROOMS).where("ROOM_room_id = " + room_id + "");
------
you should consider using:
------
select.from(TABLE_BOOKED_ROOMS).where("ROOM_room_id", "=", room_id);
------
This way your code will be safe from an SQL injection attack. If
'room_id' is an int or Integer, this is less of an issue, but it's still
a good default practice, and it's critical when you are using a String. :)
Josh
--
Joshua Hansen
Up Bear Enterprises
(541) 760-7685