Jonathan has attended:
Access Intermediate course
Count queries
I am familiar with COUNT queries, but I wondered if it was possible to COUNT within categories or ranges of values.
For example, I have 100 orders each of different amounts between
RE: Count queries
Jonothan,
You might need to do 3 separate queries until you find a better way. Create a basic query that has criteria on the AMOUNT field, and specify your range. Once this step is done, you can then count the number of records.
You could Also use a SQL statement like this:
You need to do a query where you use the Group By statement something like follows:
SELECT tblYourTable.Question1Answer, Count(tblYourTable.Question1Answer) AS MyCount
FROM tblYourTable
GROUP BY tblYourTable.Question1Answer
ORDER BY tblYourTable.Question1Answer;
tblYourTable = The name of your table.
Question1Answer = The name of the field with your answers in it.
This is one of the most powerful SQL abilities of course, but a lot of people forget that you can put a count() of in the SELECT statement to get the number of occurrences.