MariaDB中的索引键大小限制是多少?

问题描述:

在MySQL单列索引的索引键最多可达767个字节。相同的长度限制适用于任何索引键前缀。

查看和搜索MariaDB文档我找不到对此或类似限制的引用。

Reviewing and searching the MariaDB documentation I cannot find a reference to this, or a similar, limit.

这个限制是多少?

我找不到文档页面的链接是什么?

What is this limit?
What is the link to the documentation page I didn't find?

这是一个有点隐藏,但是例如

It is a bit hidden, but e.g.

https://mariadb.com/kb/en/mariadb/documentation/storage-engines/converting-tables-from-myisam-to-innodb/

说:


引擎之间INDEX的最大长度不同。
[...] MyISAM允许1000个字节; InnoDB允许767字节[...]

The maximum length of an INDEX is different between the Engines. [...] MyISAM allows 1000 bytes; InnoDB allows 767 bytes [...]

因此限制是特定于引擎的,但MySQL和MariaDB之间的限制没有区别。

So the limit is engine specific, but the limits are not different between MySQL and MariaDB.

PS:如果有疑问,MySQL和MariaDB仍然相似,任何未明确记录为不同的内容仍然是相同的

PS: if in doubt MySQL and MariaDB are still similar enough that anything that is not explicitly documented as being different is still the same