Re: issue partition scan

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

 




> On May 25, 2021, at 17:16, David Rowley <dgrowleyml@xxxxxxxxx> wrote:
> 
> It's because of the OR condition.  If it was an AND condition then the
> planner wouldn't have to consider the fact that records in other
> partitions might be required for the join.

The OP might consider rewriting the query as a UNION, with each part of the top-lkevel OR being a branch of the UNION, but excluding the partitioned table from the JOINs for the branch of the UNION that doesn't appear to actually require them.





[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux