|
|
|
Junior Member
      
Group: Forum Members
Last Login: 2/9/2007 7:35:17 AM
Posts: 15,
Visits: 9
|
|
| I am trying to join table1, table 2 and table3. The table1 has Deal_Id, Prod_Id. Table2 has Deal_Id and Table3 has Prod_Id. Now I want to write a query which will be able to retrieve records from Table3 based on Prod_Id of Table1. I also want to get the records from table2 based from Deal_Id of table1. I was trying inner join and outer join. I am getting errors. Please help.
|
|
|
|
|
Junior Member
      
Group: Forum Members
Last Login: 5/24/2007 2:30:22 PM
Posts: 10,
Visits: 2
|
|
select t2.xxx, '' from table1 t1, table2 t2 where t1.deal_id = t2.deal_id union select t3.xxx, '' from table1 t1, table3 t3 where t3.prod_id = t1.prod_id
|
|
|
|
|
Junior Member
      
Group: Forum Members
Last Login: 7/9/2007 11:05:34 PM
Posts: 10,
Visits: 1
|
|
|
|
|