6 replies
by sl-campbell
In the query designer build a new query, selecting the table in question and adding the fields that you want to average on and have in the new table.
Then go to the menu point VIEWS and select FUNCTIONS. In the grid below, on the function line, look for the field that you want to average on and change the function GroupBy to Average.
Got to the datasheet view and see if the results are correct, and then save the query.
Start a second query and for the table to use, select the query that you just created (on the Query tab).
Then select all the fields and place them into the grid.?
The select Make Table query under the menu point - Query, and give a name for the new table.
Save the query. When you run it, it will first callthe query that you made first, get the averages and then put them into the new table.
Hope this answers your question.
by sl-campbell
I need to make a comment about my answer, that DKlippert made me aware of:
I am not using the US/English version of Access and thought to remember the Menu VIEWS|FUNCTIONS to be correct when it appears to be VIEWS|TOTALS.
The purpose of doing 2 queries as in my answer is so that the first query can be used elsewhere, with-out having to make a table, and you can use the first query in as your form's recorset or to base a report on with-out having to create aother table - you can use iteverywhere almost like a table except you cannot add or edit records. Of course you can use one query to do the work, but I prefer the method of using 2. Both ways are almost identical, the one query creates one less step, but the 2 query method is more versatile.
by jgreer
by dklippert
Create a Query (Choose Query and then develop a Query using by Design or use the Wizard) and then click on the Totals button on the toolbar. You can now choose to average any appropriate field, by clicking in the Total criteria box (It will probablysay Group by by default).
When it is working correctly, go to Queries on the Menu and choose a Make table Query. This will create a Table based on your Query.
by jgreer
by jgreer
This discussion is closed to new replies.
Trending Web Development posts
Sort by Trending