歡迎您光臨本站 註冊首頁

[Microsoft][ODBC Microsoft Access Driver]可選的功能未實現

←手機掃碼閱讀     火星人 @ 2014-03-04 , reply:0

[Microsoft][ODBC Microsoft Access Driver]可選的功能未實現

org.apache.jasper.JasperException: 可選的功能未實現

在這一個方法所在的類中,"查詢","插入","刪除"功能都可以實現,就是修改功能出現
"org.apache.jasper.JasperException: 可選的功能未實現"這個錯誤.

修改部分的代碼如下:


public void update() throws Exception {
Connection conn = null;
PreparedStatement prep = null;
try {
conn = new DBConnection().getConnection();
String sql =
"UPDATE FROM STUDENT set name=?,studentNumber=?," +
"birthday=?,sex=?,polity=?,brief=? WHERE id = ? ";

prep = conn.prepareStatement(sql, ResultSet.TYPE_SCROLL_SENSITIVE,
ResultSet.CONCUR_UPDATABLE);
prep.setString(1, studentBean.getName());
prep.setString(2, studentBean.getStudentNumber());
prep.setDate(3, new java.sql.Date(studentBean.getBirthday().getTime()));
prep.setInt(4, studentBean.getSex());
prep.setInt(5, studentBean.getPolity());
prep.setString(6, studentBean.getBrief());
prep.setLong(7, studentBean.getId());
prep.execute();

} finally {
if (prep != null) {
prep.close();
}
if (conn != null) {
conn.close();
}
}

}

[火星人 ] [Microsoft][ODBC Microsoft Access Driver]可選的功能未實現已經有361次圍觀

http://coctec.com/docs/service/show-post-29937.html