Databases Querying Relational Databases Set Operations What are Set Operations?

Amadou Diallo
Amadou Diallo
5,373 Points

Why don't we just use INNER JOIN instead of INTERSECT?

Why don't we just use INNER JOIN instead of INTERSECT since they do, I think, the same thing?

1 Answer

Steven Parker
Steven Parker
200,698 Points

They can have the same final result; but a JOIN adds an additional source to a single query based on specific matching criteria, and INTERSECT combines two complete queries (two SELECTs) that return identical columns.