Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
SELECT tblSWI.Shipment_Date, tblSWI.PlannedQty,
(SELECT Sum(PlannedQty)
FROM tblSWI S
WHERE S.Shipment_Date between DateAdd("m",-12,tblSWI.Shipment_Date) and tblSWI.Shipment_Date)
AS SumLast12Months,
(SELECT Sum(PlannedQty)
FROM tblSWI S
WHERE S.Shipment_Date between DateAdd("m",-2,tblSWI.Shipment_Date) and tblSWI.Shipment_Date)
AS SumLast2Months,
(SELECT AVG(PlannedQty)
FROM tblSWI S
WHERE S.Shipment_Date between DateAdd("m",-12,tblSWI.Shipment_Date) and tblSWI.Shipment_Date)
AS AvgLast12Months,
(SELECT AVG(PlannedQty)
FROM tblSWI S
WHERE S.Shipment_Date between DateAdd("m",-2,tblSWI.Shipment_Date) and tblSWI.Shipment_Date)
AS AVGLast2Months
FROM tblSWI;
Swi said:a 12 month rolling average of how much is being used of each SKU
TRANSFORM Sum(tblData.PlannedQuantity) AS SumOfPlannedQuantity
SELECT tblData.InventoryItem, Sum(tblData.PlannedQuantity) AS [Total Usage], Avg(tblData.PlannedQuantity) AS Average
FROM tblData
GROUP BY tblData.InventoryItem
PIVOT Format([ShipmentDate],"mmm") In ("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec");