



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




1 Prepared by Ling Liu
Ling Liu Associate Professor College of Computing, Georgia Tech
2
DB05 (^) Introduction
ÆHow to lay out data on disk ) Options for Storing Records in blocks ÆHow to move it to memory
Æ Conventional indexes ÆB-trees ÆHashing schemes
3 Prepared by Ling Liu
Conventional index
z Sparse z Dense z Multi-level…
4
DB05 (^) Introduction
Dense v.s Sparse Index
z Every key in the data file is represented in the index file
z A dense index, if fits in the memory, is very efficient in locating a record given a key
z A dense index, if too big and doesn’t fit into the memory, will be expense when used to find a record given its key
7 Prepared by Ling Liu
Sequential File
Sparse Index
10 30 50 70 90 110 130 150 170 190 210 230
Normally keeps only one key per data block
8
DB05 (^) Introduction
Sequential File
Sparse 2nd level
10 30 50 70 90 110 130 150 170 190 210 230
10 90 170 250
330 410 490 570
9 Prepared by Ling Liu
Terms
10
DB05 (^) Introduction
Primary Key and Primary Index
Relation Students Name id dept SMITH 123 CS Johnson 522 EE Mary 444 CS
Note by J. Ullman
•Primary Key + Primary Index: •Option 1: Storing the relation as it is •Option 2: Storing the relation in the ascending order of id •Index: Sequential file
13
Conventional index
z Sparse z Dense z Multi-level…