Sum column data when a employee type is selected

Pam Dunn
Pam Dunn ✭✭✭✭✭

I am building a separate report referencing a sheet.

When a specific employee type is selected:

  • Freelancer

I want to to sum the numbers in these 3 columns

  • Copy3pp
  • Copy edit fl
  • copy proof fl

For a particular week.

  • In my report the Primary column is the week # 1-52
  • In sheet referencing I have a column called Week (weekof) in the formula below


=IF(CONTAINS({copywriterfl}, Freelancer), SUMIFS({Weekof}, =[Primary Column]@row, {Copy3pp}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyeditfl}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyprooffl}))

I get error unparseable.

I tried this as well: I got the same error unparseable

=IF(CONTAINS({copywriterfl}, Freelancer, SUMIFS({Weekof}, =[Primary Column]@row, {Copy3pp}, {Copyeditfl}, {Copyprooffl}))

Answers

  • Bassam Khalil
    Bassam Khalil ✭✭✭✭✭✭

    Hi @Pam Dunn

    Hope you are fine, Try adding parentheses on your formulas for text criteria as following:

    =IF(CONTAINS({copywriterfl}, "Freelancer"), SUMIFS({Weekof}, =[Primary Column]@row, {Copy3pp}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyeditfl}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyprooffl}))

    PMP Certified

    [email protected]

    ☑️ Are you satisfied with my answer to your question? Please help the Community by marking it as an ( Accepted Answer), and I will be grateful for your "Vote Up" or "Insightful"

  • Pam Dunn
    Pam Dunn ✭✭✭✭✭

    @Bassam Khalil ,

    Thank you for your response,.

    Your answer is exactly like my first formula that didn't work except for adding quotes around Freelancer. I added the quotes around Freelancer, but it is now coming back as Incorrect Argument.

  • Bassam Khalil
    Bassam Khalil ✭✭✭✭✭✭

    @Pam Dunn

    Please check the "Freelancer" in your formula I didn't see the "" ""

    PMP Certified

    [email protected]

    ☑️ Are you satisfied with my answer to your question? Please help the Community by marking it as an ( Accepted Answer), and I will be grateful for your "Vote Up" or "Insightful"

  • Pam Dunn
    Pam Dunn ✭✭✭✭✭

    Bassam,

    Thank you for your reply, but I am confused by your reply. I had provided this formula which I haven't been able to get to work.

    My original formula

    =IF(CONTAINS({copywriterfl}, Freelancer), SUMIFS({Weekof}, =[Primary Column]@row, {Copy3pp}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyeditfl}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyprooffl}))


    You replied with the following formula, the only difference I saw was adding quotes " " around Freelancer. Comparing the two formulas I did not see any difference between the parenthesis in my original formula and the one you provided. I added the quotes, but the formula still does not work.

    Your proposed new formula

    =IF(CONTAINS({copywriterfl}, "Freelancer"), SUMIFS({Weekof}, =[Primary Column]@row, {Copy3pp}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyeditfl}), SUMIFS({Weekof}, =[Primary Column]@row, {Copyprooffl}))