Which join returns only rows with matches in both tables?

Enhance your skills with the CompTIA Data+ Certification Test. Engage with flashcards, tackle challenging multiple choice questions, complete with hints and explanations. Get yourself exam-ready now!

Multiple Choice

Which join returns only rows with matches in both tables?

Explanation:
Inner joins filter results to include only rows where the join condition finds a match in both tables. It pairs each row from the first table with rows from the second table and keeps only those pairs that satisfy the condition, so rows without a corresponding match in the other table are excluded. This is exactly the behavior described by “only rows with matches in both tables.” By comparison, a cross join produces every combination of rows from both tables, regardless of matches. A right outer join keeps all rows from the right table and fills in NULLs for any missing matches on the left. A full outer join returns all rows from both tables, with NULLs where there is no match.

Inner joins filter results to include only rows where the join condition finds a match in both tables. It pairs each row from the first table with rows from the second table and keeps only those pairs that satisfy the condition, so rows without a corresponding match in the other table are excluded. This is exactly the behavior described by “only rows with matches in both tables.”

By comparison, a cross join produces every combination of rows from both tables, regardless of matches. A right outer join keeps all rows from the right table and fills in NULLs for any missing matches on the left. A full outer join returns all rows from both tables, with NULLs where there is no match.

Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy