1 / 4

Costs

Costs. Btree levels. Typical order: 100. Typical fill-factor: 67%. average fanout = 133 Typical capacities: Level 1 = 133 keys Level 2 = 133 2 ( 17689 ) keys Level 3 = 133 3 ( 2,352,637 ) keys Level 4 = 133 4 ( 312,900,700 ) keys. Costs for single relation plans on R.

betsy
Download Presentation

Costs

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Costs

  2. Btree levels • Typical order: 100. Typical fill-factor: 67%. • average fanout = 133 • Typical capacities: • Level 1 = 133 keys • Level 2 = 1332 (17689)keys • Level 3 = 1333(2,352,637)keys • Level 4 = 1334(312,900,700)keys

  3. Costs for single relation plans on R Access method Cost • Sequential scan bR • access primary key index IHeight(I) + 1 if I is B+ tree 2.2if I is hash index • clustered index I matching predicate p sel(p) x (bI +bR) • unclustered index I matching predicate p sel(p) x (bI+nR) - bR nr. of blocks of R - nR nr. of tuples of R

  4. Costs for join R with S • Block nested loop bRx bS+ bR • Indexed nested loopbR + nRxc • Hash join 3 x (bR+ bS) • Merge join if R and S are sortedbR + bS • Sort RbR( 2 logM–1(bR/ M) + 1) c- see previous slide M – nr. of buffer pages

More Related