# GATE2015-1-24

6.2k views

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. Than that index is called

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

edited
0
official ans key is c

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

selected by
4
@arjun sir why not sparse it is also ordered
12
I think clusterd index is known if the file is ordered based on the index..

and clusterd index have two type

sparse index

dense index

in sparse index for some some of the key values we have entry in index file

in dense index for every search key we have an entry in index file

although dense index could also be non clustered ...in this case for every record we have an entry
6
why not Dense indexing??
22
I guess it is because the definition of dense indexing says that for every search key value there must be an entry in the index file but it says nothing about the ordering. Dense indexing may or may not be ordered. But Clustured is always ordered.
16
Sparse index doesnot require  entry for every search key

Dense index require entry for every search key value

Clustered index requires unique entry(like primary index) for every table. Clustered index always will be sort in ascending order(whatever input u give), i.e. if u give input

1

3

2

5

4

as input

it will arrange automatically 1 2 3 4 5 in the table

i.e. why there is only 1 clustered index in a table
0
but sparse also have same order of keys just some keys are missing from the index but order will be same no ?
2
Have you read it somewhere? Because whatever places i have studied this thing from, there was no mention of sparse indexing to be necessarily ordered. If you have kindly share the link.
0
" ordering of the data records is the same as or close to the ordering of data entries in some index "

what is difference between data records and data entries in some index?

data entries means entries in each row, rt?

then what is meaning of data records?
0
I guess data records refer to the records that are there in the data file while data entries here refer to the ones in the index file.
0
So, If I think about a book

Index page each entry contains data entries

And according that entry if we go that page of the book, that is data record

rt?
0
Yes! That is what I think.
7

yes sparse index also sequential

but there every record neednot get an entry

The Line is :" ordering of the data records is the same as or close to the ordering of data entries in some index "

The good example of clustering index is telephone directory

Where the index pages start with say "M". All entries in that pages is with M or N or we can say very close to M.

That is why it is clastering index as ans

(While only book is an example of unclustered index)

17
Dense and sparse are not the types of indexes, they are only the methods to store index enteries.

Clustred is indeed a correct answer for this question!
0
@srestha

A file is organized so that the ordering of the data records is the same as  the ordering of data entries in some index. Than that index is called primary ??
0

can u give me some example?

0

A file is organized so that the ordering of the data records is the same as ordering of data entries in some index. Than that index is called

Now what can we say about this  Primary Index or Clustering Index only ..(I have removed this part  "or close to")

0
0
0
Primary index file, Clustered index file and Secondary index file is always sorted.

But Data record file is sorted  only in Primary indexing and Clustered indexing.
0

i don't know why people without know definition upvote

Clustered index requires unique entry(like a primary index) for every table. Clustered index always will be sort in ascending order(whatever input u give),

1 2 3 4 5

this definition is wrong

A clustering index is defined on the fields which are of type non-key and ordering​​​​​​​

example: 1  2  2   3    3  4  5  5 6   6  6 7

https://gateoverflow.in/414

https://gateoverflow.in/1437

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.

## Related questions

1
3.3k views
SELECT operation in SQL is equivalent to The selection operation in relational algebra The selection operation in relational algebra, except that SELECT in SQL retains duplicates The projection operation in relational algebra The projection operation in relational algebra, except that SELECT in SQL retains duplicates
Consider the DFAs $M$ and $N$ given above. The number of states in a minimal DFA that accept the language $L(M) \cap L(N)$ is_____________.
Consider a max heap, represented by the array: $40, 30, 20, 10, 15, 16, 17, 8, 4$ ... $40, 30, 20, 10, 35, 16, 17, 8, 4, 15$ $40, 35, 20, 10, 15, 16, 17, 8, 4, 30$
The binary operator $\neq$ ... the following is true about the binary operator $\neq$ ? Both commutative and associative Commutative but not associative Not commutative but associative Neither commutative nor associative