最多列。 create table test ( f1 int, f2 int, f3 int, f4 int, f5 int, f6 int, f7 int, f8 int, f9 int, f int, f int, f int, f int, f int, f int, f int, f int ); create index idx_test_ on test (f1,f2,f3,f4,f5,f6,f7,f8,f9,f,f,f,f,f,f,f); create index idx_test_ on test (f1,f2,f3,f4,f5,f6,f7,f8,f9,f,f,f,f,f,f,f,f); 运行结果如下: mysql> create table test ( -> f1 int, -> f2 int, -> f3 int, -> f4 int, -> f5 int, -> f6 int, -> f7 int, -> f8 int, -> f9 int, -> f int, -> f int, -> f int, -> f int, -> f int, -> f int, -> f int, -> f int -> ); Query OK, 0 rows affected (0. sec) mysql> mysql> create index idx_test_ on test (f1,f2,f3,f4,f5,f6,f7,f8,f9,f,f,f,f,f,f,f); Query OK, 0 rows affected (0. sec) Records: 0 Duplicates: 0 Warnings: 0 mysql> create index idx_test_ on test (f1,f2,f3,f4,f5,f6,f7,f8,f9,f,f,f,f,f,f,f,f); ERROR (): Too many key parts specified; max parts allowed mysql>
推荐整理分享MySQL一个索引最多有多少个列?真实的测试例子(mysql索引最大数量),希望有所帮助,仅作参考,欢迎阅读内容。

文章相关热门搜索词:mysql索引可以重复吗,mysql每个索引节点的大小,mysql索引可以重复吗,mysql索引数量限制,mysql索引最多包含多少列,mysql索引能存多少数据,mysql索引个数,mysql索引个数,内容如对您有帮助,希望把文章链接给更多的朋友!
MySQL里Create Index 能否创建主键 Primary Key MySQL里CreateIndex能否创建主键PrimaryKey?答案:不能,必须用Altertable创建。MySQL一个索引列最大允许的有效长度,不是列的所有数据都被索引的MyISAM是字
MySQL 创建索引(Create Index)的方法和语法结构及例子 CREATEINDEXSyntaxCREATE[UNIQUE|FULLTEXT|SPATIAL]INDEXindex_name[index_type]ONtbl_name(index_col_name,...)[index_type]index_col_name:col_name[(length)][ASC|DESC]index_type:USING{BTREE|HASH|RTREE}--创
MYSQL 优化常用方法 1、选取最适用的字段属性MySQL可以很好的支持大数据量的存取,但是一般说来,数据库中的表越小,在它上面执行的查询也就会越快。因此,在创建表