Pivot Table - calc. field the answer? If so, how?
Posted by John McTigue on May 16, 2001 8:39 AM
The original question was posted in newsgroup microsoft.public.excel.misc [message ID <0d1101c0d7fd$5c2acb20$98e62ecf@tkmsftngxs05>] with a pivot table similar to that shown here. I noticed the question had gone unanswered and asked for a sample set of data (shown below, and which is the source for the pivot table).
Original table:
Data
Country State/Province Count of Client Sum of Amount
Canada Alberta 4 100000
Ontario 5 350000
Canada Total 9 450000
USA Michigan 5 350000
New York 4 100000
Texas 4 460000
USA Total 13 910000
Original question:
"I want to add one more field (column) to the pivot table that computes the percentage of amount of each provice within the country.
I have created a field and set the option for that field to show the data as % of column. But the pivot shows me the percentage of the amount based on the Grand Total and not on the Country Total.
Is there a way that I can get the percentage based on the Country Total?"
One can view % of column total for State/Province with Country as a page field, but is it possible to get something similar to the following, ie without a page field? I have had no success but would love to know the answer, and thought I would try another set of gurus.
Required table:
Data
Country State/Province Count of Client Sum of Amount %Country
Canada Alberta 4 100000 22.2
Ontario 5 350000 77.8
Canada Total 9 450000 100.0
USA Michigan 5 350000 38.5
New York 4 100000 11.0
Texas 4 460000 50.6
USA Total 13 910000 100.0
Source data:
Country State/Province Amount Client
Canada Alberta 10000 A
Canada Alberta 20000 B
Canada Alberta 30000 C
Canada Alberta 40000 D
Canada Ontario 50000 E
Canada Ontario 60000 F
Canada Ontario 70000 G
Canada Ontario 80000 H
Canada Ontario 90000 I
USA New York 10000 A1
USA New York 20000 A2
USA New York 30000 A3
USA New York 40000 A4
USA Michigan 50000 A5
USA Michigan 60000 A6
USA Michigan 70000 A7
USA Michigan 80000 A8
USA Michigan 90000 A9
USA Texas 100000 A10
USA Texas 110000 A11
USA Texas 120000 A12
USA Texas 130000 A13