You killed it, wonderful! In this part we have learned the following:
UNION ALL – combines results from two
SELECTs. The first one emilinates the duplicates, while the other doesn't,
INTERSECT – returns all the rows present in both
EXCEPT – returns all the rows from the first
SELECT clause, that aren't present in the second,
- Remember that while using set operations, all the columns have to have the same data type.
Looks like we're done and you've mastered all there is to learn in this T-SQL basics course. By now, you should know how to:
- Deal with single and multiple tables.
- Filter results.
- Compute statistics.
JOIN tables and results.
- Perform set operations.
You can now write amazing queries all by yourself!
We've prepared a cumulative quiz to check your knowledge of all parts of this course. Give it a shot!