mysql允许最大字段多大,无法添加字段...行大小...大于最大允许大小

I'm seeing the following error in my MySQL logs:

[Warning] InnoDB: Cannot add field `wd_field_ft_95_240` in table `tmp`.`#sql_1_0` because after adding it, the row size is 8155 which is greater than maximum allowed size (8126) for a record on index leaf page.

Is this tmp database some kind of internal MySQL structure? Is this something I need to care about?

解决方案

Some MySQL queries create internal temporary tables to hold partial results.

As of MySQL 5.7.6, the default storage engine for internal temporary tables is InnoDB, which has a pretty small limit on row size, as you can see (though BLOB/TEXT columns can go beyond that limit).

You can go back to the old pre-5.7 default storage engine for internal temporary tables:

internal_tmp_disk_storage_engine=MyISAM

This is the workaround mentioned in this bug: "Bug #77398 row size too large in mysql 5.7 query"

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值