+ Reply to Thread
Results 1 to 7 of 7

SUMPRODUCT ignore text

  1. #1
    Forum Contributor
    Join Date
    08-19-2012
    Location
    Sydney
    MS-Off Ver
    MS Office 365/16
    Posts
    282

    SUMPRODUCT ignore text

    Hi all,

    I have this formula.
    Please Login or Register  to view this content.
    How do i get it to sum the numbers from D19:D44 but ignore any cells in column D that have text?

    Many thanks

  2. #2
    Forum Expert boopathiraja's Avatar
    Join Date
    07-12-2013
    Location
    Coimbatore,TamilNadu, India
    MS-Off Ver
    Excel 2007, 2013, 2016, 365
    Posts
    1,455

    Re: SUMPRODUCT ignore text

    Hi, may be this

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Click just below left if it helps, Boo?ath?

  3. #3
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: SUMPRODUCT ignore text

    Try:
    =SUMPRODUCT(('2nd_XI_Test'!$B$19:B44=A2)*ISNUMBER('2nd_XI_Test'!$D$19:D44)*'2nd_XI_Test'!$D$19:D44)
    Click the * to say thanks.

  4. #4
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: SUMPRODUCT ignore text

    Quote Originally Posted by PaulM100 View Post
    Try:
    =SUMPRODUCT(('2nd_XI_Test'!$B$19:B44=A2)*ISNUMBER('2nd_XI_Test'!$D$19:D44)*'2nd_XI_Test'!$D$19:D44)
    Hi PaulM1000, the above would error for non-numeric strings given explicit coercion (*) -- splitting the arrays, per boopathiraja, resolves that issue.

    if the D-range contains only text strings but where said strings are a mix of numeric & non-numeric (e.g. "apple" & "123") then something like below would work

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

    however, in this instance I think it's a case of numbers & text... and, given formula, a SUMIF would suffice (whose behaviour the OP is trying to replicate)

  5. #5
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: SUMPRODUCT ignore text

    I totaly missed the splitting part of it. I forgot that * and -- are not the same thing. Thank you for find that, so OP won't get a bad formula.

  6. #6
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: SUMPRODUCT ignore text

    The * and -- have same impact in that they explicitly coerce values to numeric equivalents, e.g: "0"*1 and --"0" both return same result

    The key, as you say, is splitting the arrays - separating those that need to be coerced (Booleans) from those that don't

    =SUMPRODUCT(--(booleans),values)

    some people use +0, or even *1, in preference to the double unary operator (--) when coercing the booleans -- all do the same thing

    the unary operator is considered the fastest method but it used to be buggy when used with Volatile precedents, this is no longer the case...

    and, of course, people often argue that if performance is a concern then you should not be using SUMPRODUCT to start with ;-)

  7. #7
    Forum Contributor
    Join Date
    08-19-2012
    Location
    Sydney
    MS-Off Ver
    MS Office 365/16
    Posts
    282

    Re: SUMPRODUCT ignore text

    XLent, thank you very much. This works a treat. I appreciate everyones input. You guys are amazing.

    Regards,

+ 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. [SOLVED] SUMPRODUCT ignore text in the sum range
    By chris196uk in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 06-23-2017, 12:15 PM
  2. sumproduct ignore na's
    By ammartino44 in forum Excel General
    Replies: 2
    Last Post: 07-29-2015, 03:21 PM
  3. Ignore #N/A Error In SUMPRODUCT
    By katsuya in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-14-2013, 09:14 AM
  4. [SOLVED] how to ignore text in a sumproduct, index, and match formula.
    By sbham in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 08-12-2013, 04:55 PM
  5. [SOLVED] Sumproduct, Month, Ignore text
    By jennyaccord in forum Excel General
    Replies: 7
    Last Post: 06-14-2012, 06:30 AM
  6. Sumproduct to ignore text and ""
    By Ricky Pang in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 12-10-2005, 03:40 AM
  7. [SOLVED] SUMPRODUCT excel ignore div/0
    By [email protected] in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-15-2005, 09:30 AM

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