+ Reply to Thread
Results 1 to 4 of 4

Calculated Field in Pivot Table, Not Returning Correct If Function

  1. #1
    Registered User
    Join Date
    03-09-2016
    Location
    San Marcos, Texas
    MS-Off Ver
    Office 2013
    Posts
    9

    Calculated Field in Pivot Table, Not Returning Correct If Function

    Good Morning, For the last 2 days I have been trying to fix this formula but have been unable to do so, any help would be wonderful.

    I am working on a Interview Report that basically says if they Pass of Fail the interview. Three supervisors are at the interview and they each score the interviewee if he/she makes over a score of 9 they get hired, under 9 they fail, over 12 they are over qualified, so this tells us if they are hiring the individual or not.

    This is the Pivot Table:
    Capture.JPG

    The Sum of PassFail, is the Calculated Field, I can get the IF function to return the correct numbers but not the correct text.

    Here is what I mean:

    =IF(AND(SUM(Score)>=9), "9","0") <--This Works
    =IF(AND(SUM(Score)>=9), "Pass","Fail") <--This doesn't work

    I have tried different variations of the formulas but with the same results, here are the other formulas that I have tried.
    =IF(L6>=9,"Pass","Fail") <--This doesn't work
    =IF(AND(SUM(L6)>=9), "Pass","Fail") <--This doesn't work

    Capture2.JPG

    Any help would be amazing, thank you.

    -Erik

  2. #2
    Forum Expert
    Join Date
    09-20-2011
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    2,278

    Re: Calculated Field in Pivot Table, Not Returning Correct If Function

    Hello Erik

    I don't believe you can return text like "Pass" or "Fail" into a Pivot's calculated field. You could try returning a number and custom formatting the cells to display text, for example the calculated field formula:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Would return 1 or 0, you could then apply the following Custom cell format to the calculated field column:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Hope this helps.
    DBY

  3. #3
    Registered User
    Join Date
    03-09-2016
    Location
    San Marcos, Texas
    MS-Off Ver
    Office 2013
    Posts
    9

    Re: Calculated Field in Pivot Table, Not Returning Correct If Function

    DBY, Thank you very much for your help. This is such an easy solution! I love it, This solved my issue.

    Thanks again,

    -Erik

  4. #4
    Forum Expert
    Join Date
    09-20-2011
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    2,278

    Re: Calculated Field in Pivot Table, Not Returning Correct If Function

    Glad to have helped.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Getting correct grand totals when using calculated field in pivot table
    By stephme55 in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 03-07-2016, 01:02 PM
  2. [SOLVED] A pivot table field calculated using other field values as fields?
    By chrisf78 in forum Excel Charting & Pivots
    Replies: 5
    Last Post: 05-07-2015, 03:08 AM
  3. [SOLVED] Referring to a Sub-Field on Calculated Field Pivot Table Column?
    By figo12 in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 01-27-2014, 02:02 PM
  4. Replies: 2
    Last Post: 11-05-2012, 11:32 AM
  5. Replies: 0
    Last Post: 06-26-2012, 09:06 PM
  6. [SOLVED] pivot table formulas for calculated field or calculated item
    By Vicky in forum Excel General
    Replies: 3
    Last Post: 06-06-2006, 12:10 AM
  7. [SOLVED] pivot table calculated field with user function
    By puff in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-24-2006, 06:00 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1