edited by
16,148 views
49 votes
49 votes

A file is organized so that the ordering of the data records is the same as or close to the ordering of data entries in some index. Then that index is called

  1. Dense
  2. Sparse
  3. Clustered
  4. Unclustered 
edited by

4 Answers

Best answer
45 votes
45 votes

Clustered- this is the definition of clustered indexing and for the same reason a table can have only one clustered index.

http://www.ece.rutgers.edu/~yyzhang/spring03/notes/7-B+tree.ppt

Correct Answer: C

selected by
14 votes
14 votes

Lots Of Confused Guys here.

First of All Clustering Index is done on a Field Which is NON KEY & ORDERED!

Because it is Non Key , there can be DUPLICATES, so we can’t have an Index Entry for the 1st element of the Block,we need to have an INDEX entry for each element. (For Duplicates , only one is enough).

So if Main File has DUPLICATES,then Clustered Index is also Sparse Index , bcoz we are not having index entries for the Duplicates. 

Now Answer can’t be sparse Index because if we have an INDEX Entry for every record in main File(assuming No Duplicates) , it is NOT a Sparse Index.

IN SHORT : Question says “data records is the same as or close to the ordering of data entries in some index”.

Now these data records can have duplicates ot it might not have.

If there are Duplicates, then it can’t be Dense index, else not.

If there are No duplicates , then it can’t be Sparse Index.

So only Clustering Index can be the answer.

1 votes
1 votes
Answer is C..

 

Dense index  means: you must maintain a index for every record( read agian .. it is not or evry search key) ..

1 a

1 b

2 b  

Total number of records={3}

Total number of search keys={2}

Dense contains index for 1,1,2 ..

Cluster can be either sparse or dense…

file is organized so that the ordering of the data records is the same as or close to the ordering of data entries in some index.
0 votes
0 votes
The answer is CLUSTERED not sparse because in sparse an entry is created only for some search key, only those which are first in a block while is clustered an entry is created for every distinct value.

So, clustered can give same or close to more often than sparse.
Answer:

Related questions

65 votes
65 votes
12 answers
2
28 votes
28 votes
1 answer
4
makhdoom ghaya asked Feb 13, 2015
6,931 views
Consider a max heap, represented by the array: $40, 30, 20, 10, 15, 16, 17, 8, 4$.$$\begin{array}{|l|l|}\hline \text{Array index} & \text{1} & \text{2} & \text{3} & \...