Introduction
Index-only scans help the database find data faster by using just the index without looking at the full table.
When you want to quickly find rows based on indexed columns.
When the query only needs columns stored in the index.
When you want to reduce disk reads and speed up queries.
When your table is large but the index covers all needed data.
When you want to improve performance without changing the query.