+ Reply to Thread
Results 1 to 24 of 24

SUMIF over multiple columns

  1. #1
    Registered User
    Join Date
    05-21-2005
    Posts
    4

    SUMIF over multiple columns

    is doing a SUMIF over multiple columns not allowed?

    This formula works =SUMIF(C:C,J5,E:E)
    but this does not: =SUMIF(C:C,J5,E:F)

  2. #2
    Forum Expert
    Join Date
    06-18-2004
    Location
    Canada
    MS-Off Ver
    Office 2016
    Posts
    1,474
    Try...

    =SUMPRODUCT((C1:C100=J5)*E1:F100)

    Note that SUMPRODUCT does not accept whole column references.

    Hope this helps!

    Quote Originally Posted by psmith4497
    is doing a SUMIF over multiple columns not allowed?

    This formula works =SUMIF(C:C,J5,E:E)
    but this does not: =SUMIF(C:C,J5,E:F)

  3. #3
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  4. #4
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  5. #5
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  6. #6
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  7. #7
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  8. #8
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  9. #9
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  10. #10
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  11. #11
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  12. #12
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  13. #13
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  14. #14
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  15. #15
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  16. #16
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  17. #17
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  18. #18
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  19. #19
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  20. #20
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  21. #21
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  22. #22
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  23. #23
    LanceB
    Guest

    RE: SUMIF over multiple columns

    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,f:f)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


  24. #24
    bj
    Guest

    RE: SUMIF over multiple columns

    The problem is that the criteria array and the values array needs to be the
    same size.
    you could use
    =SUMIF(C:C,J5,E:E)+SUMIF(C:C,J5,F:F)
    or
    =sumproduct(--(C1:C1000=J5),E1:E1000+F1:F1000)
    Note you cannot use full columns in Sumproduct C1:C1000 is OK C:C is not
    and the arrays need to be the same size in Sumproduct
    (E1:E1000+F1:F1000 is really just a one thousand unit array, even though it
    looks bigger)



    "psmith4497" wrote:

    >
    > is doing a SUMIF over multiple columns not allowed?
    >
    > This formula works =SUMIF(C:C,J5,E:E)
    > but this does not: =SUMIF(C:C,J5,E:F)
    >
    >
    > --
    > psmith4497
    > ------------------------------------------------------------------------
    > psmith4497's Profile: http://www.excelforum.com/member.php...o&userid=23597
    > View this thread: http://www.excelforum.com/showthread...hreadid=380121
    >
    >


+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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