在做本套視頻最后的添加區域與編輯區域信息時出現錯誤三天自己無法解決,求大神出手相救。
前面做單元測試時增刪改查方法都通過了,在最后做微信前臺向后臺傳入添加和編輯區域信息時,卻無法插入和更新數據,感覺沒有執行SQL語句一樣,網上說是SESSION沒有自動提交,搞了好久無法解決。將執行的SQL語句打印如下:
更新語句:
Creating a new SqlSession
SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@4df06b50] was not registered for synchronization because synchronization is not active
Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@4df06b50]
Creating a new SqlSession
SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@60724c05] was not registered for synchronization because synchronization is not active
Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@60724c05]
Creating a new SqlSession
SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@49e5780f] was not registered for synchronization because synchronization is not active
JDBC Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@6949521e [wrapping: com.mysql.jdbc.JDBC4Connection@5c813400]] will not be managed by Spring
==>? Preparing: update tb_area SET area_name=?, priority=? where area_id=?
Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@49e5780f]