Re: "Constraint exclusion" is not general enough

From: stark <stark(at)enterprisedb(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, pgsql-hackers(at)postgresql(dot)org, Martin Lesser <ml-pgsql(at)bettercom(dot)de>
Subject: Re: "Constraint exclusion" is not general enough
Date: 2006-08-07 09:26:27
Message-ID: 87ac6gzykc.fsf@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:

> "Jim C. Nasby" <jnasby(at)pervasive(dot)com> writes:
>
>> How many cycles are we talking about here? Is it even worth the GUC?
>
> I think so. On simple queries the optimization will *never* fire,
> and there's no point in doing the search. People who are running
> complex queries will want to turn it on, but the mysql-equivalent
> crew will just find it a waste of cycles.

The other class of people who will find this kind of thing useful are those
using automatically generated queries. Frequently you end up with redundant
clauses or "unreachable" clauses that you hope the database will be able to
see through.

Having to enable that intelligence with a GUC is fine though since those users
could just enable it even if they aren't using partitioning. That said I
expect that eventually any option we add whose only purpose is it to enable
some intelligence in the optimizer will become standard.

--
Gregory Stark
EnterpriseDB http://www.enterprisedb.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2006-08-07 09:44:42 proposal for PL packages for 8.3.
Previous Message Dave Page 2006-08-07 08:48:24 Re: 8.2 features status