6. Advanced Retrieval Operations
To this point, the queries you have read about combine and extract data from relations in relatively straightforward ways. However, there are additional operations you can perform on relations that, for example, answer questions such as “show me that data that are not …” or “show me the combination of data that are …”. In this chapter you will read about the implementation of additional relational algebra operations in SQL that will perform such queries as well as performing calculations and using functions that you can use to obtain information about the data you retrieve.
Union
Union is one of the few relational algebra operations whose name can be used in a SQL query. When you want to use a union, you write two ...
Get SQL Clearly Explained, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.