Cost of a service call
Can i caculate cost of a service call when i enter expence as Items, labors , travels.
I need a report about cost of service call.
Gordon Du replied
It will be difficult to created any Generic queries to meet your specific requirement. Try start from here:
SELECT T1.Customer, Sum(T2.Doctotal) 'Delivery', - Sum(T3.Doctotal) 'Return' from scl4 T0 Inner Join OSCL T1 On T1.CallID = T0.SrcvCallID Left Join ODLN T2 on T2.DocNum = T0.DocNumber and T0.Object = '15' Left Join ORDN T3 on T3.DocNum = T0.DocNumber and T0.Object = '16' Group By T1.customer Order By T1.customer
You can add more columns later.