Calculating a weighted average in Access

jkgreen

Board Regular
Joined
Nov 25, 2008
Messages
57
I use the SUMPRODUCT function in Excel to calculated weighted averages. How can I do the same in Access?

Thanks,
Jason
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
What about using VBA code to get results? I know I've seen it done. I just don't know VBA or how to do it.
 
Upvote 0
Hi Jason.

Can you post some sample date - inputs & outputs? In Access, as in Excel, some SQL can do the work. Basically,
Code:
SELECT SUM(Value*Quantity)/SUM(Quantity) AS [Weighted Average]
FROM source
HTH, Fazza
 
Upvote 0
Hi HTH,

With help of this forum, I have created my Document Tracking Database for my project use. Now everything is working fine except the Progress Calculation. I would like to do the progress calculcation in Access.

Progress calculation can be performed with Sumproduct function. Could you please help me to understand how we can perform Sumproduct in Access since there is no built in funtion for the same.

I would like to display the results in a form, when I click the calculate button.

I understood that We can use excel function in access by Application.Worksheet function however I don't know how to get the Query field names in the same.

Herewith I had enclosed my Database for your review.

My Formula will be like this

Sumproduct ([MHRS NEW INT],[InternalProgress])/sum(([MHRS NEW INT])

Thanks and Regards
R. Vadivelan
 
Upvote 0

Forum statistics

Threads
1,214,632
Messages
6,120,649
Members
448,975
Latest member
sweeberry

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top