Database Indexing: Which Options Are Used for Indexing?

Database Indexing: Which Options Are Used for Indexing?

Verified Sources
Sep 12, 2026

In relational database systems, indexing is primarily about building data structures (e.g., tree-based structures) that accelerate lookups for queries. A B-tree is a classic, widely used indexing data structure that keeps keys in sorted order and supports efficient searching, insertion, and deletion.

By contrast:

  • A transaction log is used for durability and recovery (e.g., to ensure the database can be restored after failures), not to speed up query lookups via key-to-row mappings.
  • A view is a stored query definition that provides a way to present data; it is not itself the physical indexing structure used by the storage engine for search.
  • A trigger is stored logic that executes automatically in response to data modifications; it is not an indexing method.

Therefore, among (i) Transaction log, (ii) B-tree, (iii) Views, (iv) Triggers, the correct choice used for indexing is (ii) B-tree.

Key terms you’ll see in this topic:

  • Index
  • B-tree
  • Transaction log
  • View
  • Trigger

Footnotes

  1. Wikipedia - B-tree. https://en.wikipedia.org/wiki/B-tree - Describes B-trees as balanced tree data structures commonly used in databases and file systems as index structures. 2

  2. Wikipedia - Transaction log. https://en.wikipedia.org/wiki/Transaction_log - Explains that the transaction log records changes for durability and recovery.

  3. Wikipedia - View (database). https://en.wikipedia.org/wiki/View_(database) - Defines views as stored queries that present data as virtual tables.

  4. Wikipedia - Database trigger. https://en.wikipedia.org/wiki/Database_trigger - Describes triggers as procedures that execute automatically in response to certain events.

Database Indexes (B-Trees) Explained

Why B-tree is used for indexing

A B-tree organizes index keys in a balanced tree structure to minimize the number of disk/page accesses needed to locate matching records. This is why B-tree (and related variants like B+ trees) are common index structures in DB engines.

Why the other options are not “used for indexing”

  • Transaction log: It supports recovery by recording database changes so the system can undo/redo operations during restart; it is not a structure for accelerating “find rows by key” operations.
  • Views: They are logical query definitions. While query planners may sometimes use indexes underneath a view’s underlying tables, the view itself is not the index data structure.
  • Triggers: They implement behavior (auto-execution on events). They may affect what data gets written, but they are not the index structure used to speed retrieval.

Footnotes

  1. Wikipedia - B-tree. https://en.wikipedia.org/wiki/B-tree - Describes B-trees as balanced tree data structures commonly used in databases and file systems as index structures.

  2. Wikipedia - Transaction log. https://en.wikipedia.org/wiki/Transaction_log - Explains that the transaction log records changes for durability and recovery.

  3. Wikipedia - View (database). https://en.wikipedia.org/wiki/View_(database) - Defines views as stored queries that present data as virtual tables.

  4. Wikipedia - Database trigger. https://en.wikipedia.org/wiki/Database_trigger - Describes triggers as procedures that execute automatically in response to certain events.

Elimination method for MCQ on ‘used for indexing’

  1. 1
    Step 1

    Indexing is about data structures that accelerate record retrieval by key (e.g., B-tree).

  2. 2
    Step 2

    Transaction log → durability/recovery; View → stored query; Trigger → automatic event-handling.

  3. 3
    Step 3

    B-tree matches because it is an index data structure for fast lookup.

  4. 4
    Step 4

    Choose (ii) B-tree.

Option-by-Option Role vs. Indexing

How each option primarily relates to indexing (high = directly an indexing mechanism).

Common exam confusions

Exam strategy

When asked ‘used for indexing,’ look for answers that are explicitly index structures (like B-tree). Avoid items that primarily describe recovery, presentation (view), or event behavior (trigger).

Footnotes

  1. Wikipedia - B-tree. https://en.wikipedia.org/wiki/B-tree - Describes B-trees as balanced tree data structures commonly used in databases and file systems as index structures.

Don’t confuse indexing with query features

Views and triggers are logical/behavioral constructs. An index is a physical/engine structure designed to accelerate search by keys (e.g., B-tree). 2

Footnotes

  1. Wikipedia - View (database). https://en.wikipedia.org/wiki/View_(database) - Defines views as stored queries that present data as virtual tables.

  2. Wikipedia - Database trigger. https://en.wikipedia.org/wiki/Database_trigger - Describes triggers as procedures that execute automatically in response to certain events.

Indexing MCQ Quick Recall

1 / 4
Question · Term

Which option is an index data structure?

Click to reveal
Answer · Definition

B-tree.

Knowledge Check

Question 1 of 4
Q1Single choice

Which of the following is used for indexing in database systems?