标签:
MySQL的timestamp类型,在java中对应的java.sql.timestamp,使用时候,使用
Timestamp create_time = new Timestamp(0);
而后插入mysql数据库时,会提示出错。要求timestamp的参数得是大于0的。
相关的页面 http://bugs.mysql.com/bug.php?id=27930
Connector/J 3.0 didn‘t care about truncation on writes. C/J 3.1 and newer do. The JDBC specification requires drivers to throw exceptions for truncations on writes. If you don‘t care about truncations (why not?), then add "jdbcCompliantTruncation=false" to your JDBC URL.
标签:
原文地址:http://www.cnblogs.com/majia1949/p/4300433.html