News for hackers. Stuff that matters.
Re:Postgres Indexes for Newbies by jandrewrogers on Wednesday January 19, 2022 @09:30PM (#30003644)
A sequential scan can be faster than an indexed search in many cases. There is a good reason optimizers often choose to do sequential scans even when an index is available. Remember, the index is displacing data in the cache. Even for data that is purely in memory, sequential scans are often friendly for CPU performance.

On modern server hardware you usually need megabytes of data in a table before sequential scans start to become suboptimal. Most database engines are designed under this assumption.

There are no comments on this comment yet.