unliar / unliar.github.io

一个已经不再使用的静态博客,新的博客在后边。
https://happysooner.com
0 stars 0 forks source link

fix Error 1071: Specified key was too long; max key length is 767 bytes #1

Open unliar opened 5 years ago

unliar commented 5 years ago
  1. it happen when create index,because large index will make mysql query slow. 发生在创建索引的时候,因为大索引可能导致查询过慢

  2. it can be fixed by change mysql config. just set innodb_large_prefix = ON 可以通过修改mysql配置生效 nnodb_large_prefix = ON