Bug #100436 Indexs that use expressions don't show up correctly in the alter table view
Submitted: 5 Aug 2020 18:19 Modified: 5 Aug 2020 20:50
Reporter: Graham Clifford Email Updates:
Status: Verified Impact on me:
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:8.0.21 OS:Mac OS X (10.15.5)
Assigned to: CPU Architecture:x86

[5 Aug 2020 18:19] Graham Clifford
A index that has one or more expressions do not show those expression on the Alter Table -> Index View.

As of MySQL 8.0.13 expressions are allow in an index.

How to repeat:
Use Schema:

CREATE TABLE `SampleTable` (
  `id` int NOT NULL,
  `name` varchar(45) DEFAULT NULL,
  `parentId` int DEFAULT NULL,
  PRIMARY KEY (`id`),
  UNIQUE KEY `SampleTableUniqueIndexName` (`name`,(ifnull(`parentId`,-(1))))
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

After Create
1) Right Click on Table in the tree
2) Click Alter Table
3) Click the index tab
4) Select the index

Notice that the expression is not shown.

Suggested fix:
A way to view all parts that make up the index.
[5 Aug 2020 20:50] MySQL Verification Team
Thank you for the bug report.