General information
Category:
Coding, syntax & commands
Title:
Facing Problem in Left Outer Join condition
Environment versions
Network:
Windows 2000 Server
Dear Experts,
I have header table and detailed table, i want to retrive all the data from header table
+ and the data from datailed table in which heder id = detailed id.
The purpose of this report to print the stock aging of items.
Once this items using for transacitn it will come to detailed table.
And which are not using will still remain in the Header file.
For calculating aging i want all the data from Header and Transaction
A-> Header table
B-> Detailed table
select A.code, A.Desc, B.Cost, B.Qty from A
Left Outer join B on A.Code = B.Code And substring(B.Voucher,1,3)= 'ABC'
this is retriving all the datas which are commen in both tables,
but i want retrive all the data same as above + some items are in eader table
which are not participate in transactions(These items are can not find in detailed file).
Or, for Example
Header Table -> 10 rows
Deatled Table -> 6 rows
Resulted table should contain 16 rows with contions as above
Tahnks in advance
Regards
Abdulla
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only