Quiz 2 - Indexing Flashcards
1
Q
table scan
A
- a sequential scan of the table
- each row is examined for inclusion in result
- it is the simplest and slowest for of search
- performance is benchmarked against table scan
2
Q
Advantages of indexing
A
- index is alphabetically sorted, therefore faster
- index is much smaller than table
- only load needed pages, instead of all of them
3
Q
index
A
- index is built for a column in a table
- a table can have more than one index
- each index entry has a search key and a pointer
- all indexes are sorted
4
Q
search key
A
- value of an attribute in the column being indexed
* part of an index entry
5
Q
pointer
A
- physical memory location where a record is stored
* part of an index entry
6
Q
ordered index
A
- table is sorted according to value in the indexed column
- each search key can have only one occurrence in the index
- index points to the first occurrence in the table
- also known as a primary or clustered index
7
Q
hash index
A
- index is sorted, but table is not
- one index record for EVERY table record
- each search key may have multiple occurences in the index
- a hash index is always dense
- also known as a secondary or non-clustered index
8
Q
primary index
A
another name for ordered index
9
Q
clustered index
A
another name for ordered index
10
Q
secondary index
A
another name for hash index
11
Q
non-clustered index
A
another name for hash index
12
Q
types of ordered indices
A
- dense
* sparse
13
Q
dense index
A
- table sorted by indexed column
- each search key key MUST have one and only one index record
- a type of ordered or hash index
14
Q
sparse index
A
- table is sorted by indexed column
- there is an index record for only SOME of the search keys
- each search key can have, at most, one index record
- a type of ordered index only
15
Q
impact to ordered index: INSERT
A
• update location values in index
• if new search key value inserted, then new record inserted to index
•