MySQL 5.7建表语句:
CREATE TABLE `4dfca143de64f9b67a59f2d4e8dde0e2_51941` (
`姓名` VARCHAR(255) COLLATE utf8mb4_bin NOT NULL,
`年龄` VARCHAR(255) COLLATE utf8mb4_bin NOT NULL,
`住址` VARCHAR(255) COLLATE utf8mb4_bin NOT NULL,
PRIMARY KEY (`姓名`)
) ENGINE=INNODB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
在MySQL 5.6执行报错如下:
错误代码: 1709
Index column size too large. The maximum column size is 767 bytes.
解决办法:
InnoDB Row Format Overview
Row Format | Compact Storage Characteristics | Enhanced Variable-Length Column Storage | Large Index Key Prefix Support | Compression Support | Supported Tablespace Types | Required File Format |
---|---|---|---|---|---|---|