Internal join: inner join or join to check the data corresponding to the two tables.
Outer Join: Outer Join, which identifies the corresponding data based on a table and is divided into left Outer Join and right outer join.
Left Outer Join: left join or left Outer Join. The corresponding data is retrieved based on a table.
Outer right join: Right join or right outer join. The corresponding data is retrieved based on a table.
Full join: Full join, based on multiple tables
Student table
No name
1
2 B
3 C
4 d
Grade table
No grade
1 90
2 98
3 95
5 90
Inner join: The data corresponding to the search condition. No data is listed in No4.
Syntax: Select * from student inner join grade on student. No = Grade. No
Result:
No name no grade
1 A 1 90
2 B 2 98
3 C 3 95
Left join: All data in the left table, corresponding data in the right table
Syntax: Select * from student left join grade on student. No = Grade. No
Result:
No name no grade
1 A 1 90
2 B 2 98
3 C 3 95
4 d
Right join: All data in the right table, corresponding data in the left table
Syntax: Select * from student right join grade on student. No = Grade. No
Result:
No name no grade
1 A 1 90
2 B 2 98
3 C 3 95
5 90
Full connection
Syntax: Select * from student full join grade on student. No = Grade. No
Result:
No name grade
1 A 90
2 B 98
3 C 95
4 d
1 A 90
2 B 98
3 C 95
Note: you cannot directly use full join in access. You must use Union all to merge the left and right connections.