C
ctfrigg
Hi!
I need to create a cross-tab query and groups my dates by quarters-year and
calcuates a percentage based on my column "Receipt Type". I am not sure how
to do this.
The calculation is the sum of an $amount when Receipt type = AMEX/sum of
all $amounts (with all receipt types)
This is what I want the end result to be
Q1-08 Q2-08 Q3-08
Op Unit 98% 92% 95%
Here is what I have so far but not sure how to do the data groupings or do
the calcuation.
TRANSFORM Sum(CorpCardCompliance_USD_AirHotel_Detail.[USD Reimburse]) AS
[SumOfUSD Reimburse]
SELECT CorpCardCompliance_USD_AirHotel_Detail.OpUnitName
FROM CorpCardCompliance_USD_AirHotel_Detail
GROUP BY CorpCardCompliance_USD_AirHotel_Detail.OpUnitName
PIVOT CorpCardCompliance_USD_AirHotel_Detail.ReportSubmittedDate;
Thank you so much for the help.
I need to create a cross-tab query and groups my dates by quarters-year and
calcuates a percentage based on my column "Receipt Type". I am not sure how
to do this.
The calculation is the sum of an $amount when Receipt type = AMEX/sum of
all $amounts (with all receipt types)
This is what I want the end result to be
Q1-08 Q2-08 Q3-08
Op Unit 98% 92% 95%
Here is what I have so far but not sure how to do the data groupings or do
the calcuation.
TRANSFORM Sum(CorpCardCompliance_USD_AirHotel_Detail.[USD Reimburse]) AS
[SumOfUSD Reimburse]
SELECT CorpCardCompliance_USD_AirHotel_Detail.OpUnitName
FROM CorpCardCompliance_USD_AirHotel_Detail
GROUP BY CorpCardCompliance_USD_AirHotel_Detail.OpUnitName
PIVOT CorpCardCompliance_USD_AirHotel_Detail.ReportSubmittedDate;
Thank you so much for the help.