-2

I've read that the Heap File Organization is usually used to structure a secondary index. This makes me suspect that usually, a secondary index is unordered, as opposed to the primary index, that is ordered by the primary key attribute. Is this true ?

1
  • 1
    Depends on the index definition and the concrete dbms? Your question can't be generally answered. Commented Oct 3, 2019 at 8:35

1 Answer 1

1

Depends on the index type. The default index type in most relational database is usually some form of btree (or other forms of search tree), which is ordered index, though they would be ordered by the indexed columns, not by the table's primary key. There are some types of secondary indexes like hash index which are unordered.

I'm not quite sure where you get the impression that "Heap File Organization is usually used to structure a secondary index". A heap file organisation the way it's described in that article isn't useful for indexing at all.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.