AI engineering glossary · SQL databases
What is INTERSECT?
INTERSECT: A set operator that returns only rows appearing in the results of both queries, with duplicates removed. Columns must match in number and compatible type. It is the set-intersection of two result sets.
INTERSECT: an example
Emails in both newsletter_subscribers and app_users, giving people on both lists.
Related terms
More SQL databases terms
- Isolation level
- Join
- Key-value store
- LAG and LEAD
- LEFT JOIN
- LIMIT and OFFSET
- Locking
- Many-to-many relationship
Where you learn it
INTERSECT is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.