Home > Backend Development > PHP Tutorial > mysql 新增多一列数据 报错 Data truncated for column 'tg_level' at row 1

mysql 新增多一列数据 报错 Data truncated for column 'tg_level' at row 1

WBOY
Release: 2016-06-13 13:09:49
Original
1315 people have browsed it

mysql 新增加一列数据 报错 Data truncated for column 'tg_level' at row 1
插入的是这个列 alter table tg_user change tg_level tg_level tinyint(1) unsigned not null 如果不加这个 not null 没有错误。求高手帮忙解答

------解决方案--------------------
他不是update, 是add, 所以很奇怪, 应该是没找到病根

探讨

把库里面原来的数据删除就行了,因为原来有数据,又设为not null ,是冲突的
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template