香港服務(wù)器導(dǎo)入sql文件時(shí)報(bào)錯(cuò)(在執(zhí)行創(chuàng)建表或者增加字段時(shí),發(fā)現(xiàn)row size長度過長,會(huì)導(dǎo)致出現(xiàn)以下錯(cuò)誤)
[ERR] 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.
[ERR] — mysql dump 10.13 Distrib 5.6.50, for Linux (x86_64)
執(zhí)行以下sql語句,查看嚴(yán)格模式是否開啟
show variables like ‘%innodb_strict_mode%’;
執(zhí)行后如果為ON,則需要關(guān)閉
Variable_name Value
innodb_strict_mode ON
找到mysql的配置文件my.ini。
右鍵編輯,在[mysqld]配置項(xiàng)下面新增一行
[mysqld]
innodb_strict_mode=0
保存,然后重啟服務(wù)。再次執(zhí)行以下sql語句,查看嚴(yán)格模式是否開啟
show variables like ‘%innodb_strict_mode%’;
如果為OFF,則說明執(zhí)行成功,再導(dǎo)入測(cè)試正常。