Grouping and averaging in a query

K

Kevin G

I have a table with a large amount of data in it (Area Codes and Prefix
[NPA-Nxx]) and I need to sort those by state. Once sorted, each Area Code
and Prefix has a cost associated with it. I'd like to average the cost per
state among all Area Codes and Prefixes in that state.

Can this be done with a query? Any help is appreciated.

Thanks,

Kevin G
 
K

Kevin G

Jeff L said:
If you just want the Average cost per state, you will need the
following:

Select State, Avg(Cost)
Group by State

Sometimes it's just too easy!!! This worked perfect!!! Thanks!!!

Kevin
 

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

Top