Professional Documents
Culture Documents
Notes On Third Class
Notes On Third Class
1. JOIN
1.1. Inner Join when 2 table have a column which are related to each other. Then, we can
join with conditional function
Ex:
2. Detailed information about JOIN (inner join, left join, right join, etc)
2.1. Inner Join
Actually, in some points, we ‘ll get same result compare to inner join using conditional,
but using this type of inner join will give you more capability to arrange the output of the
table that you want.
A. Choosing some columns to be shown.
We can choose which column we want to show. If we use the coding above all the
columns from table 1 and table 2 will be shown and the key columns are shown
twice. This is the method how to implement it.
3. UNION
If JOIN is a method to combine two tables or more horizontally, then UNION is a method to
combine it vertically.
UNION requirement:
a. The tables should have the same number of columns
b. Those columns should have the same type of data
c. Those columns should have the same sequence