Multiple choice technology programming languages

At what situation you will create Index?

  1. The column contain wide range of values.

  2. The column contain large number of Null values.

  3. The table is large.

  4. Columns which are not frequently used.

Reveal answer Fill a bubble to check yourself
A,B,C Correct answer
Explanation

Indexes are beneficial when columns contain wide range of values (high cardinality), when tables are large (performance impact is significant), and when columns contain many NULL values (indexes can efficiently skip NULLs). Columns that are infrequently used don't benefit from indexing as the query performance gain wouldn't justify the storage and maintenance overhead.