Search Postgresql Archives

Re: Postgres 11 chooses seq scan instead of index-only scan

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jan 24, 2019 at 9:01 AM twoflower <standa.kurik@xxxxxxxxx> wrote:
Yes! That was it, after running VACUUM TABLE history_translation, the query is now executed using index-only scan.

I was under the impression that ANALYZE TABLE history_translation is enough, but it is not.

Only a VACUUM will update the visibility map. https://www.postgresql.org/docs/current/storage-vm.html

I used to think the same, that ANALYZE was enough, coming from an Oracle background. I learned later that the visibility map isn't just used to determine what to vacuum, but it is used by the optimizer/planner when evaluating execution plans.
 
--
Don Seiler
www.seiler.us

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux