Re: Estimates on partial index

From: Ashish Kumar Singh <ashishkumar(dot)singh(at)altair(dot)com>
To: Victor Yegorov <vyegorov(at)gmail(dot)com>, Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>, Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
Cc: "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Estimates on partial index
Date: 2016-08-19 04:21:16
Message-ID: f506333e-1e68-40a3-82da-46cb88998d6e@asiapac.altair.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

K te er Xi

Sent from Nine<http://www.9folders.com/>
________________________________
From: Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>
Sent: 19-Aug-2016 03:32
To: Jeff Janes; Victor Yegorov
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: [PERFORM] Estimates on partial index

On 8/18/16 3:06 PM, Jeff Janes wrote:
> If you can come up with a data generator which creates data that
> others can use to reproduce this situation, we can then investigate it
> in more detail.

BTW, the easy fix to this is most likely to create an index on due_date
WHERE is_current. Or perhaps partition the table so non-current rows
don't live with current ones. I'm not a fan of mixing history tracking
in with the main table, because it leads to problems like this.
--
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com
855-TREBLE2 (855-873-2532) mobile: 512-569-9461

--
Sent via pgsql-performance mailing list (pgsql-performance(at)postgresql(dot)org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Victor Yegorov 2016-08-19 11:31:49 Re: Estimates on partial index
Previous Message pinker 2016-08-18 22:26:35 Re: Big data INSERT optimization - ExclusiveLock on extension of the table