-
Type:
Task
-
Status: Open (View Workflow)
-
Priority:
Major
-
Resolution: Unresolved
-
Fix Version/s: None
-
Component/s: Optimizer, Storage Engine - InnoDB
-
Labels:
MySQL 8.0 introduced support for descending indexes in WL#1074. This involved some changes in InnoDB and many in the optimizer.
MariaDB and older versions of MySQL silently ignore the ASC/DESC attribute in KEY definitions. All index fields (KEY_PART) are sorted in ascending order.
The Oracle database defines the NULLS FIRST and NULLS LAST attributes for the ORDER BY clause, but not for CREATE INDEX. The defaults are the exact opposite of InnoDB behaviour:
NULLS LAST is the default for ascending order, and NULLS FIRST is the default for descending order.
InnoDB in MariaDB and before MySQL 8.0 supports only ascending order, and it sorts NULLS FIRST, not NULLS LAST like the above quote suggests Oracle to do.
- relates to
-
MDEV-23571 InnoDB does not raise a warning if ALTER TABLE index operations are optimized away
-
- Open
-