Processing
 

Add Calculated Field To Pivot Table

13/09/2016 18:31#1

Joined at: 6 months ago

Post: 1

Thank: 0

Thanked: 0

I am attempting to add a calculated field to my pivot table that is attempts/success and show that as a percentage. I followed these steps

Click in pivot table
Press alt+jtjf
In the window that opens give it a name
add the formula to use

The formula I used was =['Stolen Bases']/['Attempts'] but all that this did was sum the numbers. So an example would be Bob's total would be 104 instead of 73.33%. Below is an example of how I want my pivot table with calculated column to look. Row Labels, Stolen Bases and Attempts all exist in the dataset but the Total does not that is a calculated field.

How can I add this calculated field column and have it accurately pull the percentage? Add Calculated Field To Pivot Table

EDIT

One thing that may be causing the issue...the dataset is a sql server query and field setup has structure like so

playername SBAttempts Outcome 

So my query to get stolen bases and attempts is

Select playername,  case when outcome = 'SB' then COUNT(SBAttempts) else NULL end as "Stolen Bases" case when outcome = 'OUT' then COUNT(SBAttempts) else NULL end As "Attempts" From baseballstats 

Which leaves my pivot table broken out like so:
Columns = outcome
Values = Count of SBAttempts
Rows = playername

Similar articles

Excel More conditions in one formula?

6 months ago - Reply: 2 - Views: 172

Get Workbook reference from Open File dialog

6 months ago - Reply: 2 - Views: 131

Add Calculated Field To Pivot Table

6 months ago - Reply: 0 - Views: 7

Nested IF Functions in Excel not working

6 months ago - Reply: 3 - Views: 164

Formulating Date in Excel 2013

7 months ago - Reply: 2 - Views: 88

VB6 extracts in Excel 2013

7 months ago - Reply: 2 - Views: 153

Excel 2013 : Pull Matching Data from Column

7 months ago - Reply: 1 - Views: 23

excel search and copy in/from another file

7 months ago - Reply: 0 - Views: 1

Buggy PivotTable.ColumnRange

7 months ago - Reply: 0 - Views: 6

Excel static conditional formatting area

7 months ago - Reply: 0 - Views: 8

vé máy bay vé máy bay giá rẻ ve may bay ve may bay gia re vé máy bay vé máy bay giá rẻ ve may bay ve may bay gia re vé máy bay vé máy bay giá rẻ ve may bay ve may bay gia re vé máy bay vé máy bay giá rẻ ve may bay ve may bay gia re vé máy bay vé máy bay giá rẻ ve may bay ve may bay gia re vé máy bay vé máy bay giá rẻ ve may bay ve may bay gia re vé máy bay vé máy bay giá rẻ ve may bay ve may bay gia re