mysqlindexcheck

Note that mysqlindexcheck ignores descending indexes. For example, full_name_desc (first_name descending and last_name) is treated as a duplicate index of full_name (first_name and last_name):

shell> mysqlindexcheck --server=<user>:<pass>@localhost:3306 employees --show-drops WARNING: Using a password on the command line interface can be insecure.# Source on localhost: ... connected.# The following indexes are duplicates or redundant for table employees.employees:#CREATE INDEX `full_name_desc` ON `employees`.`employees` (`first_name`, `last_name`) USING BTREE#     may be redundant or duplicate of:CREATE INDEX `full_name` ON `employees`.`employees` (`first_name`, `last_name`) USING BTREE#CREATE INDEX `first_name` ON `employees`.`employees` ...

Get MySQL 8 Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.