José Soares <jose@sferacarta.com> writes:
>> When I "explain" this, I see that I am getting a mergejoin plan.
>> Are you getting a hash join, perhaps?
> Yes.
> prova=> explain select mcode, dcode from master m, detail d where
> mcode=dcode;
> NOTICE: QUERY PLAN:
>
> Hash Join (cost=156.00 rows=1001 width=24)
> -> Seq Scan on detail d (cost=43.00 rows=1000 width=12)
> -> Hash (cost=43.00 rows=1000 width=12)
> -> Seq Scan on master m (cost=43.00 rows=1000 width=12)
>
> EXPLAIN
OK, do this:
update pg_operator set oprcanhash = 'f' where oid = 1054;
and I think you'll be OK. I will put that change into the sources.
regards, tom lane