java - ResultSet .next was not called exception is thrown -


i have query this

string sql_query = select name, display_name parameter id = (something); 

after executing query retrieved resultset, , i'm trying update value display_name. it's not working , throwing exception

.next not called.

rs = stmt.executequery(sql_query); string displayname = rs.getstring(display_name); displayname = displayname.replace("&lt;", "<"); rs.updatestring(display_name,display name); 

the problem says in error message. resultset.next() wasn't called. call it. not forgetting check return value.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -