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
 

Similar threads

btse1
Replies
0
Views
99
btse1
btse1
meetvekaria
Replies
0
Views
855
meetvekaria
meetvekaria
R
  • Richard.ACE
  • Word
Replies
1
Views
352
macropod
macropod
B
Replies
1
Views
176
macropod
macropod
I
Replies
1
Views
365
IceHockey44
I
H
Replies
0
Views
218
highstream
H
N
Replies
0
Views
255
Nate
N
H
  • HawaiianShirts
  • Word
Replies
1
Views
292
macropod
macropod
Top