mysql里的问题。
一个Statement只可以对应一个ResultSet.
By default, only one ResultSet object per Statement object can be open at the same time. Therefore, if the reading of one ResultSet object is interleaved with the reading of another, each must have been generated by different Statement objects. All execution methods in the Statement interface implicitly close a statment's current ResultSet object if an open one exists. from jdk1.4.1 api doc<转载>
一个Statement只可以对应一个ResultSet.
By default, only one ResultSet object per Statement object can be open at the same time. Therefore, if the reading of one ResultSet object is interleaved with the reading of another, each must have been generated by different Statement objects. All execution methods in the Statement interface implicitly close a statment's current ResultSet object if an open one exists. from jdk1.4.1 api doc<转载>
javax.servlet.ServletException: [Microsoft][ODBC SQL Server Driver]????????? hstmt
哪位知道的教教我啊,我真的很痛苦.....
做过asp或者jsp的都会碰到啊,我第一次做,帮帮我吧!我等
String plus="update bbsMSG set replyNum='"+num+"',appTime=getDate() where id='"+msgID+"'";
replyNum到底是int还是string?
stmt = conn.createStatement(
ResultSet.TYPE_SCROLL_INSENSITIVE,
ResultSet.CONCUR_READ_ONLY
);
如果rs没有记录,你也会发生例外。
num+=1;rs.close();int num=0;
if(rs.next())
{
num=rs.getInt("replyNum");
num+=1;
}
rs.close();