D
Dsperry101 via AccessMonster.com
Hello ,
I have a maintenance work order database. I want to do a query for a
graph. I want to show the total work orders issued in the past months. I have
done this using the query by example screen and plotted in a chart.
Now I want to add to the query and chart. Each work order has a priority
of either "Normal" , "Unsafe to Operate" or "Production Stoppage" in the
database in the field [Priority]. I want to get the count of each category of
each [Priority] for each month. I'd like plot these values on the chart also.
I've tried several things but can't seem to get it right.
Don't know it will help but here's the SQL generated:
SELECT Format(([Work_Order_Received]),"mmm-yyyy") AS MonthYearStr, Count((
[MonthYearStr])) AS MCount, CDate(Format([Work_Order_Received],"mmm-yyyy"))
AS DateDate
FROM tblNewMwo
GROUP BY Format(([Work_Order_Received]),"mmm-yyyy"), CDate(Format(
[Work_Order_Received],"mmm-yyyy"))
ORDER BY CDate(Format([Work_Order_Received],"mmm-yyyy"));
The [Work_Order_Received] field is a string value.
Thanks ahead of time
I have a maintenance work order database. I want to do a query for a
graph. I want to show the total work orders issued in the past months. I have
done this using the query by example screen and plotted in a chart.
Now I want to add to the query and chart. Each work order has a priority
of either "Normal" , "Unsafe to Operate" or "Production Stoppage" in the
database in the field [Priority]. I want to get the count of each category of
each [Priority] for each month. I'd like plot these values on the chart also.
I've tried several things but can't seem to get it right.
Don't know it will help but here's the SQL generated:
SELECT Format(([Work_Order_Received]),"mmm-yyyy") AS MonthYearStr, Count((
[MonthYearStr])) AS MCount, CDate(Format([Work_Order_Received],"mmm-yyyy"))
AS DateDate
FROM tblNewMwo
GROUP BY Format(([Work_Order_Received]),"mmm-yyyy"), CDate(Format(
[Work_Order_Received],"mmm-yyyy"))
ORDER BY CDate(Format([Work_Order_Received],"mmm-yyyy"));
The [Work_Order_Received] field is a string value.
Thanks ahead of time