用户注册测试
来源:8-3 Service-注册功能单测
合法俊哥
2020-02-15
JDBC Connection [HikariProxyConnection@1981372076 wrapping com.mysql.jdbc.JDBC4Connection@65d57e4e] will not be managed by Spring
==> Preparing: select count(1) from mall_user where email=?
==> Parameters: jack@imooc.com(String)
<== Columns: count(1)
<== Row: 0
<== Total: 1
Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@2241f05b]
Creating a new SqlSession
SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@2133661d] was not registered for synchronization because synchronization is not active
JDBC Connection [HikariProxyConnection@1821581506 wrapping com.mysql.jdbc.JDBC4Connection@65d57e4e] will not be managed by Spring
==> Preparing: insert into mall_user (id, username, password, email, phone, question, answer, role, create_time, update_time) values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
==> Parameters: null, jack(String), e10adc3949ba59abbe56e057f20f883e(String), jack@imooc.com(String), null, null, null, 1(Integer), null, null
Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@2133661d]
org.springframework.dao.DataIntegrityViolationException:
### Error updating database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Column 'create_time' cannot be null
大湿兄,我把create_time跟update_time字段通过mysql处理了,怎么还是会出现这个字段为null的问题
写回答
1回答
-
mybatis里 xml没删掉那2个字段
052020-02-19
相似问题