A computer-based method and system of processing records read respectively
from first and second related tables of a database includes determining
whether data contained in the records read from the first or second tables
is unevenly distributed. Records corresponding to evenly distributed data
are searched for matches using a first set of instances of the hash-join
operator, and records corresponding to data which is unevenly distributed
are searched for matches using a second set of instances of a hash-join
operator.