Re: Slow "not in array" operation - Mailing list pgsql-performance

From Michael Lewis
Subject Re: Slow "not in array" operation
Date
Msg-id CAHOFxGpt73epD-gYH32u9pOZJkvEO=iNstGJ+jkSkd59LuEtMQ@mail.gmail.com
Whole thread Raw
In response to Re: Slow "not in array" operation  (Marco Colli <collimarco91@gmail.com>)
Responses Re: Slow "not in array" operation  (Justin Pryzby <pryzby@telsasoft.com>)
Re: Slow "not in array" operation  (Marco Colli <collimarco91@gmail.com>)
List pgsql-performance
It is very interesting to me that the optimizer chose a parallel sequential scan rather than an index scan on either of your indexes that start with project_id that also reference trashed_at.

1) Are you running on SSD type storage? Has random_page_cost been lowered to 1-1.5 or so (close to 1 assumes good cache hits)?
2) It seems you have increased parallel workers. Have you also changed the startup or other cost configs related to how inclined the system is to use sequential scans?
3) If you disable sequential scan, what does the plan look like for this query? (SET ENABLE_SEQSCAN TO OFF;)

pgsql-performance by date:

Previous
From: Marco Colli
Date:
Subject: Re: Slow "not in array" operation
Next
From: Justin Pryzby
Date:
Subject: Re: Slow "not in array" operation