PostgreSQLQuestion 03 of 11
Clustered index — does the PRIMARY KEY order the table?
Answer out loud or in your head first, then compare.
Answer
In PostgreSQL a PRIMARY KEY usually creates a unique B-tree index, but it doesn't automatically keep the table physically ordered by the key.
CLUSTER table USING index rewrites the table in index order once. Later writes don't keep that order.
To be precise: this differs from the common understanding of a clustered index in SQL Server. You have to map interview terminology to the specific engine.
Pitfall: CLUSTER needs a strong lock and extra resources. I don't run it routinely in production just because an index exists. I always establish the goal and the operational cost.
How did it go? Be honest — “Not yet” puts the question on your review list.