GK Question

technology medium mcq

Which SQL clause is used to combine the result sets of two or more SELECT statements?

  1. JOIN
  2. MERGE
  3. UNION
  4. COMBINE

Answer: UNION

UNION combines result sets of multiple SELECT queries into a single result, removing duplicates by default. UNION ALL retains duplicates and is faster. Requirements: same number of columns, compatible data types, and same column order. Useful for consolidating data from similar tables or partitioned datasets.

Topic Database & Programming
Exam Relevance Banking, SSC JE, Railway