Bird
0
0

Which of the following is the correct syntax to create a new text search configuration named my_config based on the built-in english configuration?

easy📝 Syntax Q12 of 15
PostgreSQL - Full-Text Search
Which of the following is the correct syntax to create a new text search configuration named my_config based on the built-in english configuration?
ACREATE TEXT SEARCH CONFIGURATION my_config AS english;
BCREATE TEXT SEARCH CONFIGURATION my_config FROM english;
CCREATE TEXT SEARCH CONFIGURATION my_config ( COPY = english );
DCREATE TEXT SEARCH CONFIGURATION my_config LIKE english;
Step-by-Step Solution
Solution:
  1. Step 1: Recall correct CREATE syntax

    PostgreSQL uses CREATE TEXT SEARCH CONFIGURATION name ( COPY = existing_config ) to copy an existing config.
  2. Step 2: Check options

    Only CREATE TEXT SEARCH CONFIGURATION my_config ( COPY = english ); uses the correct syntax with COPY = english. Others use invalid keywords.
  3. Final Answer:

    CREATE TEXT SEARCH CONFIGURATION my_config ( COPY = english ); -> Option C
  4. Quick Check:

    Use COPY = for cloning configs [OK]
Quick Trick: Use COPY = existing_config to clone search configs [OK]
Common Mistakes:
  • Using FROM or AS instead of COPY =
  • Omitting parentheses around COPY clause
  • Confusing syntax with table creation

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More PostgreSQL Quizzes