NMB Webmaster <webmaster(at)nmb(dot)it> writes:
> I have two database quite similar, one has more tables than the other.
Are both of them vacuumed/analyzed recently? The slow plan seems to be
estimating many more rows out of the e/m join than the other one.
> My Postgres version is 7.2.3. Please help me , it is very important to
> me to tune this query.
I'd recommend an update, myself. 7.2.3 is old...
regards, tom lane