News for hackers. Stuff that matters.
Re:How good are query optimizers, really? [pdf] (2015) by why-el on Monday July 13, 2020 @10:52PM (#23827984)
You can also disable seq_scan and force pg to consider indexes, usually that's enough.
Re:How good are query optimizers, really? [pdf] (2015) by iracic on Tuesday July 14, 2020 @03:11AM (#23829336)
Access method is just part of the story. Same index may be accessed in different ways, you might also want to combine them. Sometimes you may change table join order to see how it estimates (or executes). Usually there are two parts 1) cost and reasoning for some estimation 2) how it executes (timings, resource usage, locks/contention)