Please HELP..rs.getString or rs.getAttribute??
843835Dec 3 2001 — edited Dec 3 2001Hi I have a function that gets the value and I store it into a variable. I just want to print this to see that infact I have captured it properly.
1) code for that part --
sql1 = "Select distinct next_gun() as id from dummy ";
rs = stmt.executeQuery(sql1);
...then
out.println(rs.getString("id"));
-----the error I get --
Prepared statement not a cursor-specification
2) Also when I do insert this I know in ASP you would put rs("id")
but in JSP how would I do this?
"INSERT INTO person(ID, SSN) "+
"VALUES (" +
"'" + rs("id") + "', " +
"'" + SSN + "')";
???
Thanks for looking at this!!