How to check if select query is returning more than one value in java -


i executing select query through preparedstatment, have raise exception in basis of if resultset contains more 1 value,so question how determine rs returning multiple values.?

try this:

resultset lresult = stmt.executequery("select a,b,c yourtable"); boolean lmorethanone = lresult.first() && lresult.next(); 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -