数据库
首页 > 数据库> > mysql 一次插入多个text字段类型的数据

mysql 一次插入多个text字段类型的数据

作者:互联网

mysql插入的一行数据中有多个text类型的字段时报错如下:

错误代码: 1118
Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help. In current row format, BLOB prefix of 768 bytes is stored inline.

1. 首先text字段较多,参数一般会比较大,设置max_allowed_packet为合适的大小;

2. 参照错误提示, "Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help",修改表的行格式为"DYNAMIC"或“COMPRESSED”;

 

 

标签:BLOB,FORMAT,text,DYNAMIC,字段,COMPRESSED,mysql,ROW
来源: https://www.cnblogs.com/lijianchuan/p/13271593.html