+ Reply to Thread
Results 1 to 9 of 9

HELP CONVERT SUMPRODUCT to COUNTIFS

Hybrid View

  1. #1
    Registered User
    Join Date
    03-09-2013
    Location
    ontario
    MS-Off Ver
    Excel 2007
    Posts
    5

    HELP CONVERT SUMPRODUCT to COUNTIFS

    so my formula is this

    =SUMPRODUCT(--(B27:B8999<>E27:E8999))

    how to convert this to the proper countifs?

    the logic to my formula is it is suppose to count how many records of Column B has changed in Column E.

    TIA.

  2. #2
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,677

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    You can't do that with COUNTIFS because COUNTIF/COUNTIFS will compare each value in col B against a fixed criteria - you effectively have a different criteria for every row - best to stick with your current formula, is it working OK?
    Audere est facere

  3. #3
    Registered User
    Join Date
    03-09-2013
    Location
    ontario
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    Quote Originally Posted by daddylonglegs View Post
    You can't do that with COUNTIFS because COUNTIF/COUNTIFS will compare each value in col B against a fixed criteria - you effectively have a different criteria for every row - best to stick with your current formula, is it working OK?
    yes it's working fine on my excel but for other versions of excel it doesn't work. Im currently using excel 2007.

  4. #4
    Forum Contributor
    Join Date
    02-28-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    272

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    If possible attach the sample file

  5. #5
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,677

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    Your formula should work OK in all excel versions - did you test it in another version?

  6. #6
    Registered User
    Join Date
    03-09-2013
    Location
    ontario
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    Any other formulas other than sumproduct that I could use then besides countif to count changes between 2 columns?

  7. #7
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    why are you so anti sumproduct?
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  8. #8
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,677

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    There aren't really any better ways, or any need to change as far as I know. SUMPRODUCT is often used because it avoids the need for an array formula. All other options are very similar, e.g.

    =SUM(--(B27:B8999<>E27:E8999))

    but needs to be confirmed with CTRL+SHIFT+ENTER

    or this similar version

    =SUM(IF(B27:B8999<>E27:E8999,1))

    also confirmed with CTRL+SHIFT+ENTER

    ....or just use a helper column, e.g. in Z27 copied down

    =IF(B27<>E27,1,0)

    now just sum column Z for the total number

  9. #9
    Registered User
    Join Date
    03-09-2013
    Location
    ontario
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: HELP CONVERT SUMPRODUCT to COUNTIFS

    Quote Originally Posted by daddylonglegs View Post
    There aren't really any better ways, or any need to change as far as I know. SUMPRODUCT is often used because it avoids the need for an array formula. All other options are very similar, e.g.

    =SUM(--(B27:B8999<>E27:E8999))

    but needs to be confirmed with CTRL+SHIFT+ENTER

    or this similar version

    =SUM(IF(B27:B8999<>E27:E8999,1))

    also confirmed with CTRL+SHIFT+ENTER

    ....or just use a helper column, e.g. in Z27 copied down

    =IF(B27<>E27,1,0)

    now just sum column Z for the total number
    thank you so much now it works fine!

+ 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