Вы можете группировать по продуктам и использовать условное агрегирование:
SELECT
[Product_ID/No], [Product_Name],
SUM(IIF(DATESERIAL(YEAR(DATE()), MONTH(DATE()), 1) = DATESERIAL(YEAR([Date]), MONTH([Date]), 1), Revenue, NULL)) AS Current_Month,
SUM(IIF(DATESERIAL(YEAR(DATEADD("m", -1, DATE())), MONTH(DATEADD("m", -1, DATE())), 1) = DATESERIAL(YEAR([Date]), MONTH([Date]), 1), Revenue, NULL)) AS Previous_Month,
Nz(Current_Month)- Nz(Previous_Month) AS Variance
FROM Sales
GROUP BY [Product_ID/No], [Product_Name]
Результаты:
Product_ID/No Product_Name Current_Month Previous_Month Variance
A APPLE 110 50 60
B BANANA 100 150 -50
C CHERRY 50 -50