I have devloped an application(windows). In which I'm joing two tables.
table like
Table1->Order | PostnigDate| Quantity | MatDoc |
----------------------------------------------------------------------
1 | 10/13/2009 | 1000 | 523EW |
1 | 10/13/2009 | 1000 | 100WT |
3 | 10/13/2009 | 454 | E23E44 |
Table2->|Order | PDate | Quantity | coulm1 | coulm2.....
--------------------------------------------------------------------------------
1 | 10/13/2009 | 1000 | 2W32 | 231
1 | 10/13/2009 | 1000 | 2W32 | 332
Im fetching 1st row from 1st Table and matching it rows from Table2 with and Order, PDate and Quantity.
So I got 2matching rows 4m Table2.
Again for 2nd Row from 1st Table I'm getting 2 matching rows.
I wants Logic that will match 1st row from Table1 with 1stRow from Table2.(out of all matching row)
And 2nd row from Table1 with 2nd Row from Table2..(out of all matching row)
In above Case I got 4rows. where 2row should be there 1 to 1 relation.
Reply