Search Postgresql Archives

Re: Odd Row Estimates in Query Plan (rows=75)

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

 



On Wed, Aug 15, 2018 at 3:31 PM, Adrian Klaver <adrian.klaver@xxxxxxxxxxx> wrote:

        lts.date_added  > '2017-07-14 11:13:05'

and
       
        lts.date_gifted >= '2017-08-13 11:13:05'
?

In other words one '>' and the other '>=' ?

The date_added filters were added just to use that index and with a broad range, since there isn't a filter on date_gifted. You'll notice the date_added range is 30 days but the date_gifted range is 3 hours. We really only care about date_gifted but at this time there isn't an index on that field.

Even as I experiment with some query rewrites, the EXPLAIN ANALYZE always says rows=75. I'm *very* curious to see why it is using that value.

Don.

--
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