logoalt Hacker News

kebsup • today at 11:31 AM • 0 replies • view on HN

I was using postgres for embarrassingly long time before I've learned the difference between "index scans" and "index only scans".

Including relevant columns in the index can massively improve the performance, because postgres does not need to read the randomly sorted tuple in the original table.