On Jun 22, 2007, at 10:16 , Fernando Schapachnik wrote:
> EXPLAIN SELECT DISTINCT p.id
Can you provide EXPLAIN ANALYZE? I suspect that when you rewrote the
query it changed how the planner took into account the statistics. If
your statistics are off, perhaps this changes how the planner
rewrites the query.
Michael Glaesemann
grzm seespotcode net