Re: Data point on the competition regarding selectivity of unknown parameters - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Data point on the competition regarding selectivity of unknown parameters
Date
Msg-id 5914.1094047100@sss.pgh.pa.us
Whole thread Raw
In response to Data point on the competition regarding selectivity of unknown parameters  (Greg Stark <gsstark@mit.edu>)
List pgsql-hackers
Greg Stark <gsstark@mit.edu> writes:
> One of the things I think has to change with postgres is the default
> selectivity assumptions for inequality operators. They're way to high
> currently.

Maybe so, but 5% is grossly too low.  We'd just be throwing ourselves
into a different set of badly misoptimized queries.  On what grounds can
you argue that "WHERE x > y" will select only 5% of the rows, if you
have no knowledge about either x or y?  (And no, I won't buy the
argument that users are only interested in queries that fetch small
proportions of tables.  That argument comes from thinking of only one
class of applications.)

Perhaps more to the point, 5% is still too high to ensure selection of
an indexscan.  You'd need something more like 0.5%, which is even more
obviously hopelessly misguided.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Jeff
Date:
Subject: Re: version upgrade
Next
From: Joe Conway
Date:
Subject: Re: version upgrade