Query Processing and Optimization
Query Processing and Optimization
Query Processing and Optimization
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
• Statistics<br />
Operation 2: n followed by a π<br />
• Relation statistics: r CheckedOut = 40,000 b CheckedOut = 2,000<br />
• Attribute statistics: s FilmID = 8<br />
• Index statistics: Secondary B + -Tree Index for CheckedOut on<br />
FilmID with 2 levels.<br />
• Result relation size: 8 tuples.<br />
• Operation: Index join using B + -Tree, then project on<br />
CustomerID. Leave result in main memory (one block).<br />
• Cost: C 2 = 1 +1 + 8 = 10<br />
42