Hi,
My initial crosstab is as thus:
TRANSFORM Sum([ct AllCallsAdjSurgDt].Quantity) AS SumOfQuantity
SELECT [ct AllCallsAdjSurgDt].Hub_Name, [ct AllCallsAdjSurgDt].Kit_No, Sum([ct AllCallsAdjSurgDt].Quantity) AS [Total Of Quantity]
FROM [ct AllCallsAdjSurgDt]
WHERE ((([ct AllCallsAdjSurgDt].AdjustedSurgeryDate) Between #6/1/2014# And #8/1/2014#))
GROUP BY [ct AllCallsAdjSurgDt].Hub_Name, [ct AllCallsAdjSurgDt].Kit_No
PIVOT [ct AllCallsAdjSurgDt].AdjustedSurgeryDate;
Now I need a second query, whereby I have the exact same column headings as the above CT (2 months worth of data currently but will grow) but for each date I need the sum of the current column plus the next 3 columns. The Dates have been adjusted to eliminate weekends.
The absolute final result is a union of these two crosstabs.
Clear as mud?
Thanks for your help!
C
My initial crosstab is as thus:
TRANSFORM Sum([ct AllCallsAdjSurgDt].Quantity) AS SumOfQuantity
SELECT [ct AllCallsAdjSurgDt].Hub_Name, [ct AllCallsAdjSurgDt].Kit_No, Sum([ct AllCallsAdjSurgDt].Quantity) AS [Total Of Quantity]
FROM [ct AllCallsAdjSurgDt]
WHERE ((([ct AllCallsAdjSurgDt].AdjustedSurgeryDate) Between #6/1/2014# And #8/1/2014#))
GROUP BY [ct AllCallsAdjSurgDt].Hub_Name, [ct AllCallsAdjSurgDt].Kit_No
PIVOT [ct AllCallsAdjSurgDt].AdjustedSurgeryDate;
Now I need a second query, whereby I have the exact same column headings as the above CT (2 months worth of data currently but will grow) but for each date I need the sum of the current column plus the next 3 columns. The Dates have been adjusted to eliminate weekends.
The absolute final result is a union of these two crosstabs.
Clear as mud?
Thanks for your help!
C