Query Performance / Planner estimate off

2020-10-20 Thread Mats Julian Olsen
Dear Postgres community, I'm looking for some help to manage queries against two large tables. Context: We run a relatively large postgresql instance (5TB, 32 vCPU, 120GB RAM) with a hybrid transactional/analytical workload. Data is written in batches every 15 seconds or so, and the all queryable

Re: Query Performance / Planner estimate off

2020-10-20 Thread Mats Julian Olsen
On Tue, Oct 20, 2020 at 9:50 AM David Rowley wrote: > On Tue, 20 Oct 2020 at 22:38, Mats Julian Olsen > wrote: > > > > The crux of our issue is that the query planner chooses a nested loop > join for this query. Essentially making this query (and other queries) take

Re: Query Performance / Planner estimate off

2020-10-20 Thread Mats Julian Olsen
On Tue, Oct 20, 2020 at 10:50 AM Pavel Stehule wrote: > > > út 20. 10. 2020 v 11:59 odesílatel Mats Julian Olsen < > m...@duneanalytics.com> napsal: > >> On Tue, Oct 20, 2020 at 9:50 AM David Rowley >> wrote: >> >>> On Tue, 20 Oct 2020 at 22:3

Re: Query Performance / Planner estimate off

2020-10-20 Thread Mats Julian Olsen
On Tue, Oct 20, 2020 at 11:16 AM Pavel Stehule wrote: > > > út 20. 10. 2020 v 13:09 odesílatel Mats Julian Olsen < > m...@duneanalytics.com> napsal: > >> >> >> On Tue, Oct 20, 2020 at 10:50 AM Pavel Stehule >> wrote: >> >>> >>