If you mean group by Source and Category, you'd need to add that to the derived tables and then join on that, e.g.:
SELECT A.Source, A.Category, A.TotalExtCost, B.TotalExtCostSO, A.TotalExtCost-NZ(B.TotalExtCostSO,0) AS StockExtCost
FROM
(SELECT Source, Category, Sum(ExtCost) AS TotalExtCost
FROM MRPSPartsSales_12months
GROUP BY Source, Category) AS A LEFT JOIN
(SELECT Source, Category, Sum(ExtCost) AS TotalExtCostSO
FROM MRPSPartsSalesSO_12months
GROUP BY Source, Category) AS B ON A.Source = B.Source AND A.Category = B.Category
GROUP BY A.Source, A.Category, A.TotalExtCost, B.TotalExtCostSO, A.TotalExtCost-NZ(B.TotalExtCostSO,0);