On 6 Feb, To: tgl@sss.pgh.pa.us wrote:
> On 5 Jan, Tom Lane wrote:
>> Josh Berkus <josh@agliodbs.com> writes:
>>> 2) DEVELOP BETTER PLANS FOR "OR GROUP" QUERIES
>>
>>> Summary: Currently, queries with complex "or group" criteria get devolved by
>>> the planner into canonical and-or filters resulting in very poor execution on
>>> large data sets. We should find better ways of dealing with these queries,
>>> for example UNIONing.
>>
>>> Description: While helping OSDL with their derivative TPC-R benchmark, we ran
>>> into a query (#19) which took several hours to complete on PostgreSQL.
http://developer.osdl.org/markw/dbt3-pgsql/
There's a short summary of the tests I ran over the weekend, with links
to detailed retults. Comparing runs 43 (7.4) and 52 (7.5devel), it
looks like query #7 had the only significant improvement. Oprofile data
should be there too, if that'll help. Let us know if there's anything
else we can try for you.
Mark