Thread: slow hashjoin - NTUP_PER_BUCKET again

slow hashjoin - NTUP_PER_BUCKET again

From
Pavel Stehule
Date:
Hello

I try to identify of our slow queries - we have lot of queries like
select count(*) from a,b where a.a = b.b;

our servers has usually enough memory (we do OLAP) - we use some
pooling for limiting memory expensive queries - and I found so
hashjoin based queries are significantly slower than mergejoin
queries.

The profiler show me a most expensive function ExecScanHashBucket.
When I decrease NTUP_PER_BUCKET from 10 to 3, then there was 2 times
speedup of these queries.

Can I expect some issue with using lower value in production?

Regards

Pavel Stehule