Join Examsbook
478 0

Q: What is UNION , UNION ALL?

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

Both these are used to combine the results of different SELECT statements.     UNION       - Selects only distinct values      UNION ALL - Selects duplicate values also   Syntax:     SELECT column_name(s) FROM table1     UNION / UNION ALL     SELECT column_name(s) FROM table2; Notice that each SELECT statement within the UNION must have the same number of columns. The columns must also have similar data types. Also, the columns in each SELECT statement must be in the same order.

Are you sure

  Report Error

Please Enter Message
Error Reported Successfully