bugl
bugl
HomeLearnPatternsSearch
HomeLearnPatternsSearch

Loading lesson path

Learn/SQL/SQL References
SQL•SQL References

SQL UNION ALL Keyword

Concept visual

SQL UNION ALL Keyword

Pointer walk
two pointers
leftright102132436485116
left=0
right=6
1
3

Start at both ends

UNION ALL Keyword

Previous

❮ SQL Keywords

Next

Union All

The UNION ALL

command combines the result set of two or more SELECT statements (allows duplicate values).

The following SQL statement returns the cities

(duplicate values also) from both the "Customers" and the "Suppliers" table:

Example

SELECT City FROM Customers

Union All

SELECT City FROM Suppliers

ORDER BY City;

Previous

❮ SQL Keywords

Next

Previous

SQL UNION Keyword

Next

SQL UNIQUE Keyword