Bird
0
0

Which SQL command correctly creates a B-tree index on the column email of the table users?

easy📝 Syntax Q3 of 15
SQL - Indexes and Query Performance
Which SQL command correctly creates a B-tree index on the column email of the table users?
ADROP INDEX idx_email ON users (email);
BCREATE INDEX idx_email ON users (email);
CINSERT INDEX idx_email INTO users (email);
DCREATE TABLE idx_email ON users (email);
Step-by-Step Solution
Solution:
  1. Step 1: Recall correct syntax for creating an index

    The correct syntax is CREATE INDEX index_name ON table_name (column_name);
  2. Step 2: Match options to syntax

    Only CREATE INDEX idx_email ON users (email); matches the correct syntax for creating a B-tree index.
  3. Final Answer:

    CREATE INDEX idx_email ON users (email); -> Option B
  4. Quick Check:

    Index creation syntax = CREATE INDEX [OK]
Quick Trick: Use CREATE INDEX to build B-tree indexes [OK]
Common Mistakes:
  • Using CREATE TABLE instead of CREATE INDEX
  • Trying to INSERT an index
  • Using DROP instead of CREATE

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More SQL Quizzes