Hello,
I would like to make a dynamic report from a crosstab query that will have a different date range everytime it is run. It will be computing a quarterly compliance percentage. The crosstab query is based on a table that was created using two queries to compute values.
The table (tblDeptSummary) has the following fields:
Dept (text)
MthYr (which is mm/yyyy format)
Compliance (number)
My crosstab query is as follows:
TRANSFORM Avg(tblDeptSummary.compliance) AS AvgOfcompliance
SELECT tblDeptSummary.Dept, Round(Avg([compliance])) AS [Total Of compliance]
FROM tblDeptSummary
GROUP BY tblDeptSummary.Dept
PIVOT tblDeptSummary.MthYr;
When I create report, I would like to have a form pop up asking for the date range parameter - begindate & enddate.
I tried to put the parameter in the crosstab query, but not sure how to get it to work when the date is in month/year format. The next thing I'm not sure how to do is make the report column headings dynamic. The departments will be the rows and I'd like the 3 months in the quarter as the column headings.
I've looked at various dynamic crosstab query report examples, but can't seem to figure out how to get an example to work for me.
I appreciate any suggestions. Thank you.
I would like to make a dynamic report from a crosstab query that will have a different date range everytime it is run. It will be computing a quarterly compliance percentage. The crosstab query is based on a table that was created using two queries to compute values.
The table (tblDeptSummary) has the following fields:
Dept (text)
MthYr (which is mm/yyyy format)
Compliance (number)
My crosstab query is as follows:
TRANSFORM Avg(tblDeptSummary.compliance) AS AvgOfcompliance
SELECT tblDeptSummary.Dept, Round(Avg([compliance])) AS [Total Of compliance]
FROM tblDeptSummary
GROUP BY tblDeptSummary.Dept
PIVOT tblDeptSummary.MthYr;
When I create report, I would like to have a form pop up asking for the date range parameter - begindate & enddate.
I tried to put the parameter in the crosstab query, but not sure how to get it to work when the date is in month/year format. The next thing I'm not sure how to do is make the report column headings dynamic. The departments will be the rows and I'd like the 3 months in the quarter as the column headings.
I've looked at various dynamic crosstab query report examples, but can't seem to figure out how to get an example to work for me.
I appreciate any suggestions. Thank you.