hi,
I new to access and an having trouble with joining muytliple tables... If i use the total and sum the two columns i need, it doubles the amount. I have run the query with no total and every row is doubled. I cant seem to see why this is happening and how to fix it.
Can anyone help?
Thanks
Blunder
I new to access and an having trouble with joining muytliple tables... If i use the total and sum the two columns i need, it doubles the amount. I have run the query with no total and every row is doubled. I cant seem to see why this is happening and how to fix it.
Can anyone help?
Thanks
Blunder
Code:
SELECT COS_MAP.[Market of Settlement - Short Name], Entity_Map.[Entity name (re-worked)], AsiaandDTCVolume.[Russ - Region] AS [Processing Center], Depot_Map.[Market Partner], Sum(AsiaandDTCVolume.[Good Trades BO]) AS [Settlement Volume], Sum(NonABCFails.[Russ - Fails No]) AS [Fail Number], AsiaandDTCVolume.[Firm Depo Clearing Location ID], AsiaandDTCVolume.[Firm's Nostro Clearing Location ID], Depot_Map.Country, Depot_Map.[Depot Name]
FROM (((AsiaandDTCVolume LEFT JOIN COS_MAP ON AsiaandDTCVolume.[Market of Settlement Code] = COS_MAP.[Market of Settlement Code]) LEFT JOIN Entity_Map ON AsiaandDTCVolume.[Entity Id (OPP)] = Entity_Map.[Entity ID]) LEFT JOIN NonABCFails ON (AsiaandDTCVolume.[Firm's Nostro Clearing Location ID] = NonABCFails.[Firms Nostro Clearing Location Id]) AND (AsiaandDTCVolume.[Market of Settlement Code] = NonABCFails.[Market of Settlement Code]) AND (AsiaandDTCVolume.[Firm Depo Clearing Location ID] = NonABCFails.[Firms Depot Clearing Location Id])) LEFT JOIN Depot_Map ON AsiaandDTCVolume.[Firm Depo Clearing Location ID] = Depot_Map.Depot
GROUP BY COS_MAP.[Market of Settlement - Short Name], Entity_Map.[Entity name (re-worked)], AsiaandDTCVolume.[Russ - Region], Depot_Map.[Market Partner], AsiaandDTCVolume.[Firm Depo Clearing Location ID], AsiaandDTCVolume.[Firm's Nostro Clearing Location ID], Depot_Map.Country, Depot_Map.[Depot Name];