Re: [HACKERS] optimizer pruning problem
Roberto Cornacchia <rcorna@tin.it>
From: Roberto Cornacchia <rcorna@tin.it>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-hackers@postgresql.org
Date: 1999-09-07T19:15:37Z
Lists: pgsql-hackers
Thanks a lot for your explanations.
We have started working with the snapshot and have found a problem with
the selectivity estimation of join clauses, probably you just know of
this.
When the join is between attnos < 0 (such as oids), the selectivity is
estimated as 0.5 (leading to very bad size estimates), since this code
in function compute_clause_selec (clausesel.c):
if (relid1 > 0 && relid2 > 0 && attno1 > 0 && attno2 > 0)
...
else
s1 = (Cost) (0.5);
So what is the aim of the last two and conditions?
Best regards
Roberto Cornacchia
Andrea Ghidini