How to change the Subtotal of my Pivot table to use subtraction instead of Summing

I

Irene Chew

I have the following Pivot table created:

---------------------------------------------------------------------------
Sum of HEAD_COUNT DEPT

PER_GROUP TYPE HQ HRD ED PD CFD
--------- ---- -- --- -- -- ---
ACCOUNTING 1APPROVED 0 0 0 0 0 0
2ACTUAL 0 0 0 0 0 0
ACCOUNTING Total 0 0 0 0 0 0

ADMINISTRATIVE 1APPROVED 0 1 0 0 0 0
2ACTUAL 0 0 0 0 0 0
ADMINISTRATIVE Total 0 1 0 0 0 0

CORPORATE SUP 1APPROVED 1 0 37 1 8 7
2ACTUAL 1 0 35 1 8 7
CORPORATE SUP Total 2 0 72 2 16 14

----------------------------------------------------------------------------

The Substotal line were created by summing up the two rows of data
from the same PER_GROUP. Eg, 37 + 35=72. However, for my requirement,
i need to perform subtraction of this two rows of data, ie, 37 - 35 =
2, to show the available Head_count. How can i change my Pivot Table
to use Subtraction in the Subtotal, likewise for the Grand Total, it
should be summing up all the subtotal lines from each PER_GROUP.
please adivse.
 
D

Dave Peterson

I think I'd use a helper column in the original data:

Equivalent Headcount.
With a formula like:
=if(x2="1Approved",y2,-y2)

If the options were 1Approved or 2Actual.
 

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