152k views
3 votes
What type of join returns all records from one table and only matching records from the other table? This join matches records with NULL when there isn't a match in the other table.

1) Inner Join
2) Left Join
3) Right Join
4) Full Outer Join

User Ali Azam
by
7.1k points

1 Answer

2 votes

Final answer:

The type of join that returns all records from one table and only matching records from the other table, matching records with NULL when there isn't a match in the other table, is the Left Join.

Step-by-step explanation:

The type of join that returns all records from one table and only matching records from the other table, matching records with NULL when there isn't a match in the other table, is the Left Join.

In a Left Join, all the records from the left (or first) table are returned, and only the matching records from the right (or second) table are included in the result.

For example, if we have a table of customers and a table of orders, a Left Join would return all the customers, along with any orders they have made, and NULL values for customers who have not made any orders.

User Ad Rees
by
6.7k points