Average Table Columns


1

116

I have a DRW that I would like to get the average of each column. I can add
another results sections, but like to see some script to do so, so I don't
have to add another results section to the page.

Thanks for any assist
David
 
Ad

Advertisements

S

Stefan B Rusynko

Presuming the database field you are averaging is numeric,
- and all fields have values (to get a true average),
- use the same techniques as getting the SUM of a field named myAmount at:
http://spiderwebwoman.com/resources/dbrwtipsandtricks.asp#sum

But change it to use the Access AVG function:
SELECT AVG(myAmount) AS MyAvg


--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
_____________________________________________


I have a DRW that I would like to get the average of each column. I can add
another results sections, but like to see some script to do so, so I don't
have to add another results section to the page.

Thanks for any assist
David
 

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


Top