there can be only one TIMESTAMP column with CURRENT_TIMESTAMP in DEFAULT or ON U

 这是因为在低版本(比如5.0)的mysql中,当2个字段同时设置为timestamp,在设其中一个的default为current_timestamp时会遇到。

此时只要换成高版本的mysql,如5.5以上就不会有这样的问题。

refurl:http://blog.suchasplus.com/2011/06/there-can-be-only-one-TIMESTAMP-column-with-CURRENT-TIMESTAMP-in-DEFAULT-or-ON-UPDATE-clause.html

扫描二维码关注公众号,回复: 1251106 查看本文章

猜你喜欢

转载自wandejun1012.iteye.com/blog/1983482
今日推荐