pivot table sum of column divide by count of another column

iknowu99

Well-known Member
Joined
Dec 26, 2004
Messages
1,158
Hi All, on the left, row labels, is weekday. Center pivot table has sum of sales and count of vendors as two columns. I know i can copy values to different space and divide the two but perhaps it's possible inside the pivot table?
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
I tinkered with this and couldn't figure it out... Only way I could see to do is add a column to the raw data and fill it with 1's. Obviously after that you can calculated field that is sum of sales divided by sum of 1's...
Excel Workbook
ABCD
1WeekdayVendorVendorCountSales
2MondayABC1100
3MondayABC1100
4MondayDEF150
5MondayDEF150
6MondayDEF150
Sheet1
 
Upvote 0
Data:

Vendor ProductCost Dates
A 300 1/1/2011
B 400 1/3/2011
C 500 1/6/2011
A 400 1/5/2011
E 500 1/1/2011
A 600 1/12/2011
G 700 1/15/2011




Result Pivot table is:

RowLabels SumofProductCost CountofDates
A 1300 3
B 400 1
C 500 1
E 500 1
G 700 1
Grand Total 3400 7



in the resulting table how to have sumofProductCost divide by CountofDates inside the pivot table options?
 
Upvote 0
Not sure I follow - wouldn't you just add Product Cost to the Data field a second time setting as Average (rather than Sum) - you can use a source field as a Data field more than once
 
Upvote 0
these pivots get pretty massive and with all data forgot what i was after....gotta laugh at it.....averages:)
 
Upvote 0

Forum statistics

Threads
1,214,943
Messages
6,122,380
Members
449,080
Latest member
Armadillos

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