Alternative Plans 2With Indexes
With clustered index on bid of Reserves, we get 100,000/100 = 1000 tuples on 1000/100 = 10 pages.
INL with pipelining (outer is not materialized).
- Decision not to push ratingɱ before the join is based on
availability of sid index on Sailors.
- Cost: Selection of Reserves tuples (10 I/Os); for each,
must get matching Sailors tuple (1000*1.2); total 1210 I/Os.
- Join column sid is a key for Sailors.
- At most one matching tuple, unclustered index on sid OK.