Average by Month

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How do I calculate an average by month? I do not want to use a cross tab
query since I just want the row to be the month and the data to be the
average sales for the month.
 
If you're storing the month and year in separate fields, this is an example
of the query that you'd use:

SELECT Avg(DataField), MonthField, YearField
FROM TableName
GROUP BY MonthField, YearField;


If you're storing the date in a single field, then this is an example of the
query:

SELECT Avg(DataField), Month(DateField), Year(DateField)
FROM TableName
GROUP BY Month(DateField), Year(DateField);
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Calculating Monthly Averages in a Query 1
Calculating an Average 11
Average of Totals 6
vba 0
Average of Subtotals in Pivot Table 0
Calculating Subsets of Data 7
group by month 9
"Rolling" quarterly average 3

Back
Top