mysql change innodb_large_prefix

我的梦境 提交于 2019-11-29 07:31:08

Between 5.6.3 and 5.7.7 (that is if you are running MySQL 5.6 or MariaDB 10.0), there are 4 steps:

  • SET GLOBAL innodb_file_format=Barracuda;
  • SET GLOBAL innodb_file_per_table=ON;
  • ROW_FORMAT=DYNAMIC; -- or COMPRESSED (goes on end of CREATE)
  • innodb_large_prefix=1

Note

SELECT * FROM information_schema.INNODB_SYS_TABLESPACES;

will provide the file_format and row_format. Some other I_S tables provide clues of file_per_table.

I'm using Mysql 5.6.17 with WAMP Server I solved the problem by editing the my.ini file Find the category [mysqld] there add the following instructions

[mysqld]
innodb_file_format = Barracuda
innodb_large_prefix = 1
innodb_file_per_table = ON

Don't forget to save the changes and restart all services.

Arsath
mysql> set global innodb_file_format = `BARRACUDA`;
mysql> set global innodb_large_prefix = `ON`;
Robert Hilson

Go to your xampp and add this query:

`mysql>` set global innodb_file_format = `BARRACUDA`;
`mysql>` set global innodb_large_prefix = `ON`;

For a permanent solution, pls add following in your mariadb My.INI file-

## Innodb settings to bypass error of max size 737
innodb-file-format=barracuda
innodb-file-per-table=ON
innodb-large-prefix=ON
## Above 3 didnot work so i added below
innodb_default_row_format = 'DYNAMIC'

I was using 10.1.38

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!