针对mysql建表语句中报索引过长问题

Specified key was too long; max key length is 767 bytes

针对mysql建表语句中报索引过长问题
① 执行
show variables like ‘%innodb_large_prefix%’;
针对mysql建表语句中报索引过长问题
若value值为off,则执行
set global innodb_large_prefix=on;

② 执行
show variables like ‘%innodb_file_format%’;
针对mysql建表语句中报索引过长问题

若innodb_file_format 与innodb_file_format_max 的value值非Barracuda
则执行:
set global innodb_file_format=Barracuda;
set global innodb_file_format_max=Barracuda;

③再在建表语句后添加 ROW_FORMAT=DYNAMIC
如:
针对mysql建表语句中报索引过长问题

相关文章:

  • 2022-12-23
  • 2021-09-22
  • 2021-08-29
  • 2022-02-16
  • 2022-12-23
  • 2021-12-02
  • 2022-01-26
猜你喜欢
  • 2022-12-23
  • 2021-08-25
  • 2022-02-02
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案