HomeInterview QuestionsWhat is the difference between clustering and non-…

What is the difference between clustering and non-clustering indexes?

🟡 Medium Conceptual Junior level
1Times asked
Jul 2026Last seen
Jul 2026First seen

💡 Model Answer

A clustering index determines the physical order of rows in a table; there can be only one clustering index per table, and the data is stored on disk in that order. A non-clustering (or secondary) index is a separate structure that contains key values and pointers to the actual rows. Multiple non-clustering indexes can exist. Clustering indexes are useful when range queries on the key are common, as the data is contiguous. Non-clustering indexes are better for lookups on columns that are not the primary key, but they require an extra lookup to fetch the row data.

This answer was generated by AI for study purposes. Use it as a starting point — personalize it with your own experience.

🎤 Get questions like this answered in real-time

Assisting AI listens to your interview, captures questions live, and gives you instant AI-powered answers on a discreet on-screen overlay.

Get Assisting AI — Starts at ₹500