NewWork mode: your Claude Code or Codex on work calls, answering from your project's codeSkip to content
Senior1 view

What types of indexes in MySQL have you worked with?

Practice

Asked at

AI answer

In your answer, it’s important to name not only the types, but also the queries for which you used them. For example: I use B-tree indexes most often—regular, unique, and composite indexes; I choose composite indexes based on column order and query conditions. I’ve also used covering indexes to reduce table lookups, and FULLTEXT for full-text search. In InnoDB, the primary key is clustered, and secondary indexes store a reference to it.

I check indexes with EXPLAIN and take their maintenance cost into account: they use space and slow down inserts and updates. The specific list should reflect your actual experience; for example, mention SPATIAL or functional indexes only if you have really worked with them.