I have 3 tables that has the same columns name.
The first Table is PriceList1
id name price
1. A 6
2. B 4
The second is PriceList2
id name price
1. C 3
2. D 1
The third is PriceList3
id name price
1. E 5
2. F 6
I want to combine these tables into one table
id name price
1. A 6
2. B 4
1. C 3
2. D 1
1. E 5
2. F 6
I use
Select * from PriceList1 p1 left join PriceList2 p2 on p1.id = p2.id join PriceList3 p3 on p3.id = p1.id
And I use left outer join, join, right outer join, right join.
I always got something like this.
id name price id name price id name price
1. A 6 1. C 3 1. E 5
........