EDUCBA

EDUCBA

MENUMENU
  • Free Tutorials
  • Certification Courses
  • 120+ Courses All in One Bundle
  • Login
Home Excel Excel Resources Excel Tips Pivot Table Formula in Excel
Secondary Sidebar
Excel Functions
  • Excel Tips
    • Recover Document in Excel
    • Excel Shortcut to Select Row
    • Excel Header Row
    • Excel Insert Button
    • Excel Translate
    • Budget in Excel
    • KPI Dashboard in Excel
    • Blank Invoice Excel Template
    • Write Formula in Excel
    • Auditing Tools in Excel
    • Autofit Row Height in Excel
    • Formatting Text in Excel
    • Add Rows in Excel Shortcut
    • Divide Cell in Excel
    • Compare Two Columns in Excel for Matches
    • Excel Troubleshooting
    • Unprotect Excel Workbook
    • Subtract Date in Excel
    • Carriage Return in Excel
    • Negative Numbers in Excel
    • Worksheets in Excel
    • Excel Match Multiple Criteria
    • Exponential Moving Average Formula
    • Sentence Case in Excel
    • Excel Reverse Order
    • Excel Timesheet Template
    • Weighted Average in Excel
    • CTRL Shift-Enter in Excel
    • Excel Expense Tracker
    • INDEX MATCH Function in Excel
    • Percent Change in Excel
    • Drag and Drop in Excel
    • Shade Alternate Rows in Excel
    • Excel Database Template
    • Inverse Matrix in Excel
    • New Line in Excel Cell
    • Format Cells in Excel
    • Excel Text with Formula
    • Project Management Template in Excel
    • Vlookup vs Index Match
    • Embedded in Excel
    • Count Colored Cells in Excel
    • Excel Hacks
    • Column Header in Excel
    • Database Function in Excel
    • Excel Spell Check
    • Linear Interpolation in Excel
    • Convert Excel to CSV
    • Excel Not Responding
    • Delta Symbol in Excel
    • Excel Mortgage Calculator
    • Excel Show Formula
    • Break Links in Excel
    • VLOOKUP Examples in Excel
    • Alternate Row Color Excel
    • Checklist in Excel
    • Microsoft Office Tips
    • Excel vs Access
    • Excel Change Case
    • Count Characters in Excel
    • Formula Bar in Excel
    • Invoice Template in Excel
    • Find and Replace in Excel
    • PowerPivot in Excel
    • Wildcard in Excel
    • Line Break in Excel
    • NULL in Excel
    • Text Formula in Excel
    • Family Tree in Excel
    • Insert Calendar in Excel
    • Page Setup in Excel
    • Search For Text in Excel
    • Switching Columns in Excel
    • 3D Cell Reference in Excel
    • Roadmap Template in Excel
    • Cell References in Excel
    • Excel Automation
    • Matching Columns in Excel
    • Evaluate Formula in Excel
    • How to Find Mean in Excel
    • How to Add Cells in Excel
    • Project Timeline in Excel
    • TODAY Formula in Excel
    • Poisson Distribution in Excel
    • YEAR Formula in Excel
    • REPLACE Formula in Excel
    • Create Spreadsheet in Excel
    • SEARCH Formula in Excel
    • HYPERLINK Formula in Excel
    • Pivot Table with Multiple Sheets
    • COLUMNS Formula in Excel
    • DAY Formula in Excel
    • RIGHT Formula in Excel
    • INDIRECT Formula in Excel
    • Excel IRR Formula
    • Pivot Table Sort
    • OR Formula in Excel
    • Pivot Table Formula in Excel
    • How to Edit Drop Down List in Excel?
    • WEEKDAY Formula in Excel
    • Chart Wizard in Excel
    • Time Difference in Excel
    • Lookup Table in Excel
    • SUBTOTAL Formula in Excel
    • LOOKUP Formula in Excel
    • Themes in Excel
    • Group Worksheets in Excel
    • Excel ISNUMBER Formula
    • 3D Maps in Excel
    • VLOOKUP Tutorial in Excel
    • Moving Columns in Excel
    • Grouping Columns in Excel
    • Excel Formula of Percentage
    • Excel Leading Zeros
    • Timesheet in Excel
    • Nested IF Formula in Excel
    • SUMIF Formula in Excel
    • Concatenation in Excel
    • Excel Insert Page Break
    • LEN Formula in Excel
    • Insert Comment in Excel
    • Excel Print
    • Fractions in Excel
    • Excel Add a Column
    • Borders in Excel
    • Excel Sum by Color
    • Excel vs Google Sheets
    • Calculate Percentage Increase in Excel
    • Excel Format Phone Numbers
    • Excel Search Box
    • Excel vs CSV
    • Excel vs Numbers
    • Excel Concatenate Date
    • Excel Bullet Points
    • Calculate Compound Interest in Excel
    • Find External Links in Excel
    • Excel Comma Style
    • Excel Remove Leading Spaces
    • Combine First and Last Name in Excel
    • How to Calculate Ratio in Excel
    • SUMPRODUCT Function with Multiple Criteria
    • Create Excel Template
    • Excel Greater than or Equal
    • Excel Keyboard Shortcuts
    • Excel Row vs Excel Column
    • Excel Operators
    • Excel Text Compare
    • Excel Uppercase Function
    • Excel Auto Numbering
    • Watermark in Excel
    • Excel Delete Row Shortcut
    • Excel Word Count
    • Row Count in Excel
    • Excel Grade Formula
    • Excel Percentage Difference
    • Excel Rows and Columns
    • Excel Group
    • Excel Move Columns
    • Excel Row Height
    • Excel Sparklines
    • Excel Drawing a line
    • Multiple IFS in Excel
    • Excel Strikethrough
    • Numbering in Excel
    • Share Excel Workbook
    • Excel Shortcut For Merge Cells
    • Excel OneDrive
    • Excel Track changes
    • Excel Hide Formula
    • Excel Filter Shortcuts
    • Excel 3D Reference
    • Protect Excel Workbook
    • Excel Moving Averages
    • Excel Row Limit
    • Excel Absolute Value
    • Excel Print Area
    • Excel Format Painter
    • Excel Separate text
    • Excel Autofit
    • Excel Columns to Rows
    • Excel Paste Shortcut Option
    • Excel Rows to Columns
    • Excel Insert Row Shortcut
    • Excel Extensions
    • Excel Unmerge Cells
    • Divide in Excel Formula
    • Excel Compare Two Columns
    • Not Equal To Excel
    • Excel Remove Duplicates
    • Excel Remove Spaces
    • Excel Calculate Age
    • Copy Excel Sheet
    • Excel Conditional Formatting Based on Another Cell Value
    • Excel Cell Reference
    • Excel Split Cell
    • Excel Circular Reference
    • Highlight Every Other Row in Excel
    • Errors in Excel
    • Excel Delete Pivot Table
    • Excel Pivot Table
    • Subtraction in Excel
    • Count Unique Values in Excel
    • Excel Highlight Duplicates
    • Excel Data Formatting
    • Random Numbers in Excel
    • Page Numbers in Excel
    • Excel CAGR Formula
    • Excel Combine cells
    • IFERROR with VLOOKUP in Excel
    • Column Sort in Excel
    • Print Comments in Excel
    • Cheat Sheet of Excel Formulas
    • Remove Hyperlinks in Excel
    • Remove (Delete) Blank Rows in Excel
    • Relative Reference in Excel
    • Subscript in Excel
    • Superscript in Excel
    • Excel Insert Multiple Rows
    • Excel Absolute Reference
    • Unhide Columns in Excel
  • Excel Functions (12+)
  • Excel Tools (114+)
  • Financial Functions in Excel (17+)
  • Logical Functions in Excel (14+)
  • Lookup and Reference Functions in Excel (36+)
  • Maths Function in Excel (47+)
  • TEXT and String Functions in Excel (26+)
  • Date and Time Function in Excel (24+)
  • Statistical Functions in Excel (59+)
  • Information Functions in Excel (4+)
  • Excel Charts (56+)
  • Workplace Productivity (4+)
  • Microsoft Office Tools (15+)
  • Excel Formula and Functions (22+)
  • MS Excel Shortcuts (4+)
Excel Functions Courses
  • EXCEL COURSE
  • Online Excel Data Analysis Course
  • Excel for Finance Course

Pivot Table Formula in Excel

By Madhuri ThakurMadhuri Thakur

Pivot Table Formula in Excel

Pivot Table Formula in Excel (Table of Content)

  • Pivot Table Formula in Excel
  • Custom Field to Calculate Profit Amount
  • Advanced Formula in Calculated Field

Pivot Table Formula in Excel

In Excel, we can add and modify the formula available in default calculated fields once we create a pivot table. To see and update the pivot table formula, create a pivot table with relevant fields we want to keep. After selecting or putting the cursor on it, select Calculated Fields from the drop-down list of Fields, Items & Sets from Analyze menu ribbon. There we will be able to see all the fields used in the pivot table along with the section Name and Formula section.

Start Your Free Excel Course

Excel functions, formula, charts, formatting creating excel dashboard & others

Custom Field to Calculate Profit Amount

You can download this Pivot Table Formula Excel Template here – Pivot Table Formula Excel Template

This is the most often used calculated field in the pivot table. Please take a look at the below data; I have Country Name, Product Name, Units Sold, Unit Price, Gross Sales, COGS (Cost of Goods Sold), Date, and Year column.

Pivot Table Formula in Excel 1

Let me apply the pivot table to find the total sales and total cost for each country. Below is the pivot table for the above data.

Pivot Table Formula in Excel 2

Pivot Table Formula in Excel 3

The problem is I don’t have a profit column in the source data. I need to find out the profit and profit percentage for each country. We can add these two columns to the pivot table itself.

Step 1: Select a cell in the pivot table. Go to Analyze tab in the ribbon and select Fields, Items, & Sets. Under this, select Calculated Field.

Pivot Table Formula in Excel 4

Step 2: In the below dialog box, give a name to your new calculated field.

Pivot Table Formula in Excel 5

Step 3: In the Formula section, apply the formula to find the Profit. The formula to find the Profit is Gross Sales – COGS.

Go inside the formula bar > Select Gross Sales from the below Field and double click it will appear in the Formula bar.

Pivot Table Formula in Excel 6

Now type minus symbol ( – ) and select COGS > Double click.

Pivot Table Formula in Excel 7

Step 4: Click on ADD and OK to complete the formula.

Pivot Table Formula in Excel 7.1

Step 5: Now, we have our TOTAL PROFIT Column in the pivot table.

Pivot Table Formula in Excel 8

This calculated field is flexible, it is not only limited to Country-wise analysis, but we can use this for all kinds of analysis. If I want to see the analysis country-wise and product-wise, I just have to drag and drop the product column to the ROW field; it will show the breakup of profit for each product under each country.

Pivot Table Formula in Excel 9

Pivot Table Formula in Excel 10

Step 6: Now, we need to calculate the profit percentage. The formula to calculate the Profit Percentage is Total Profit / Gross Sales.

Go to Analyze and again select Calculated Field under Fields, Items, & Sets.

Step 7: Now, we must see the newly inserted calculated field Total Profit in the Fields list. Insert this field to the formula.

Pivot Table Formula in Excel 11

Step 8: Type divider symbol (/) and insert Gross Sales Field.

Pivot Table Formula in Excel 12

Step 9: Name this Calculated Field as Profit Percentage.

Pivot Table Formula in Excel 13

Step 10: Click on ADD and OK to complete the formula. We have Profit Percentage as the new column.

Pivot Table Formula in Excel 14

Advanced Formula in Calculated Field

Whatever I have shown now is the basic stuff of Calculated Field. In this example, I will show you the advanced formulas in pivot table calculated fields. Now I want to calculate the incentive amount based on the profit percentage.

If the Profit % is >15% incentive should be 6% of the total profit.

If the Profit % is >10% incentive should be 5% of the total profit.

If the Profit % is <10% incentive should be 3% of the total profit.

Step 1: Go to Calculated Field and open the below dialog box. Give the name as Incentive Amount.

Advanced Formula in Calculated Field 1

Step 2: Now, I will use the IF condition to calculate the incentive amount. Apply the below formulas as shown in the image.

=IF (‘ProfitPercentage’>15%, ‘TotalProft’*6%, IF(‘ProfitPercentage’>10%, ‘Total Proft’*5%, ‘Total Proft’ *3%))

Advanced Formula in Calculated Field 2

Step 3: Click on ADD & OK to complete. Now we have an Incentive Amount column.

Advanced Formula in Calculated Field 3

Limitation of Calculated Field

We have seen the wonder of Calculated Fields, but it has some of the limitations as well. Now take a look at the below image; if I want to see the breakup of the Product-wise Incentive amount, we will have the wrong SUB TOTAL & GRAND TOTAL of INCENTIVE AMOUNT.

Advanced Formula in Calculated Field 4

So be careful while showing the Subtotal of calculated fields. It will show you the wrong amounts.

Get a List of All the Calculated Field Formulas

If you do not know how many formulas are there in the pivot table calculated field, you can get the summary of all these in a separate worksheet.

Go to Analyze > Fields, Items, & Sets –> List Formulas.

Advanced Formula in Calculated Field 5

It will give you a summary of all the formulas in a new worksheet.

Advanced Formula in Calculated Field 6

Things to Remember About Pivot Table Formula in Excel 

  • We can delete, modify all the calculated fields.
  • We cannot use formulas like VLOOKUP, SUMIF, and many other ranges involved formulas in calculated fields, i.e. all the formulas which require range cannot be used.

Recommended Articles

This has been a guide to Pivot Table Formula in Excel. Here we discussed the Steps to Use Formula of Pivot Table in Excel along with Examples and downloadable excel template. You may also look at these useful functions in excel –

  1. Pivot Table in Excel
  2. Excel Delete Pivot Table
  3. VBA Pivot Table
  4. VBA Refresh Pivot Table
Popular Course in this category
Excel Training (23 Courses, 9+ Projects)
  23 Online Courses |  9 Hands-on Projects |  110+ Hours |  Verifiable Certificate of Completion
4.9
Price

View Course

Related Courses

Excel Data Analysis Training (17 Courses, 8+ Projects)4.9
Excel for Finance Training (18 Courses, 7+ Projects)4.8
Primary Sidebar
Footer
About Us
  • Blog
  • Who is EDUCBA?
  • Sign Up
  • Live Classes
  • Corporate Training
  • Certificate from Top Institutions
  • Contact Us
  • Verifiable Certificate
  • Reviews
  • Terms and Conditions
  • Privacy Policy
  •  
Apps
  • iPhone & iPad
  • Android
Resources
  • Free Courses
  • Excel Charts
  • Excel Tips
  • All Tutorials
Certification Courses
  • All Courses
  • Excel VBA Course - All in One Bundle
  • VBA Course
  • Excel Data Analysis Course
  • Excel for Marketing Course
  • Excel for Finance Course
  • Excel for HR Training

ISO 10004:2018 & ISO 9001:2015 Certified

© 2023 - EDUCBA. ALL RIGHTS RESERVED. THE CERTIFICATION NAMES ARE THE TRADEMARKS OF THEIR RESPECTIVE OWNERS.

EDUCBA
Free Excel Course

Excel functions, formula, charts, formatting creating excel dashboard & others

By continuing above step, you agree to our Terms of Use and Privacy Policy.
*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA

*Please provide your correct email id. Login details for this Free course will be emailed to you

Let’s Get Started

By signing up, you agree to our Terms of Use and Privacy Policy.

EDUCBA

*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA

*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA

Download Pivot Table Formula Excel Template

EDUCBA Login

Forgot Password?

By signing up, you agree to our Terms of Use and Privacy Policy.

EDUCBA

Download Pivot Table Formula Excel Template

EDUCBA

डाउनलोड Pivot Table Formula Excel Template

This website or its third-party tools use cookies, which are necessary to its functioning and required to achieve the purposes illustrated in the cookie policy. By closing this banner, scrolling this page, clicking a link or continuing to browse otherwise, you agree to our Privacy Policy

Loading . . .
Quiz
Question:

Answer:

Quiz Result
Total QuestionsCorrect AnswersWrong AnswersPercentage

Explore 1000+ varieties of Mock tests View more