Slideshow:
|
We must now find:
|
best ⋈1 = null; best ⋈2 = null; best_cost = ∞; for ( ⋈1 = {one-pass, 2-pass, 3-pass, ...} ) do { for ( ⋈2 = {one-pass, 2-pass, 3-pass, ...} ) do { if ( memory-requirement(⋈1, ⋈2) ≤ M ) { if ( cost(⋈1, ⋈2)) < best_cost ) { best ⋈1 = ⋈1; best ⋈2 = ⋈2; } } } } |
We will illustrate the search algorithm with a few examples next....
|
B(R) × B(S) B(R ⋈ S) = ----------------------- = k blocks max( V(R,x), V(S,x) ) |
We will vary the the value k and study the effect.
|