MySQL 8.0 has a rich set of features. One of the feature which interests DBA’s more is invisible index
What is an index in MySQL ?
- The indexes are used to find rows with specific column values quickly. Without an index, MySQL must begin with the first row and then read through the entire table to find the relevant rows.
What is invisible index ?
- The invisible index is ability to mark an index as unavailable for use by optimizer.
- In MySQL 5.7 and other previous versions the indexes are visible by a default.
- To control the index visibility for a new index ,use a visible or invisible key words as a part of the index creation.
How to add a invisible index on existing table ?
Syntax :
…[Read more]