+ Reply to Thread
Results 1 to 22 of 22

#Value! Error Using SumProduct

  1. #1
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    #Value! Error Using SumProduct

    I am working with a dataset consisting of email addresses, blank spaces, dates, and various other information. I am using a SumProduct that checks a Date column, ensuring that the date is no earlier than the present day, and also checks an email column to ensure that there is an email address there. I need a count of the total email addresses in a specific column based on the date. The formula I'm using now returns the #value! error:

    C43 is the date that the table was last updated in the numeral form (6/19/2018 = 43270). Overall_Pop_Date is a dynamic range that looks as so:

    Overall_Pop_TPA is another dynamic range that is used to help define the range where the email addresses will fall:

    The table of dates and email addresses will be added to and lengthened which is why the dynamic range is necessary.

    I believe the error is coming from the blank cells in the column after the search operation is performed. With a blank cell, the search operation would return an error value. I thought the isnumber operator would fix this, reading the error as false, which is why I'm stumped.

    PS: I can't provide the data table as it would be a violation of our privacy practices, however I'm happy to describe the table in more detail.

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: #Value! Error Using SumProduct

    Hi, welcome to the forum

    I understand that you cannot share the actual file with us, nor would we want you to However, perhaps a dummy mock-up of your file?

    Having said all that, perhaps you would be better off using COUNTIFS, instead of SP?
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    I would love to share the actual formula's thaI'm using but because I am such a new user, the website does not allow me to post formula's as text. I could PM the formula's however if that would make it easier?

    I don't think a countif would be easier, maybe that just because I'm not sure how to use countif combined with istext but the sumproduct way has been working all throughout the rest of my workbook so I'm not sure why I'm struggling with this particular issue.

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: #Value! Error Using SumProduct

    You can PM the formulas to me, and I can copy there here for the other members to work on, too

  5. #5
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,496

    Re: #Value! Error Using SumProduct

    surveyasc are you getting a Sucuri warning trying to post the formula? If so then just place an extra space before or after (or both) around the greater than or less than signs if they are in your formula.
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  6. #6
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: #Value! Error Using SumProduct

    A couple of thoughts:-

    Are the dynamic ranges all of equal size? If not that could cause the formula to fail, although I would think with a #N/A rather than #Value error.

    Have you missed out, or misplace some of the parentheses in the formula? This could cause text (including any formula in the table that returns a blank) to be incorrectly evaluated as numeric, which would be one of the more likely causes of the error you are seeing.

    As I could see no other relevance to it, I assume that C43 should be used as the 'present day' for the formula purpose, rather than actaul date =TODAY()

    Based on your description in your original post, your formula should look something like.

    PHP Code: 
    =SUMPRODUCT((Overall_Pop_Date>=C43)*(Overall_Pop_TPA<>"")) 
    Which as Ford suggested might be better replace with countifs

    PHP Code: 
    =COUNTIFS(Overall_Pop_Date,">="&C43,Overall_Pop_TPA,"<>"
    Does that help?

  7. #7
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    I tried the sumproduct that you proposed:
    =SUMPRODUCT((Overall_Pop_Date>=C43)*(Overall_Pop_TPA<>""))

    however it did not work Jason.b75, instead of a #value! error now it is a #N/A error

  8. #8
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    Sambo Kid, I am not receiving a Sucuri error as far as I know, everything I know has been posted.

    I PM'd FDibbins my formulas so hopefully he posts those soon so that they can I've you more perspective on the problem. Appreciate the help so far everyone!

  9. #9
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: #Value! Error Using SumProduct

    That implies that the two dynamic ranges are not of equal size.

    I don't see why you can't post formulas, another member who only joined today was able to do so.

    There are problems with certain combinations of < and > being misinterpreted by the board software as html, of some other form of browser code. Copy and paste your formula to the forum, but insert a space before and after any occurrence of < or > before trying to submit your post.

    In addition to the formula you are trying to use in your sheet, the formulas used to define the named ranges may also be needed in order to find the root of the problem.

  10. #10
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    I'll try again,

    the error keeps saying I cant post any kinds of links, image or videos until I post a few more times.

    I'll keep trying

  11. #11
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: #Value! Error Using SumProduct

    How are you trying to post the formula?

    You need to click in the formula bar and copy the text of the formula, not just copy the cell.

  12. #12
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    I know the defined dynamic ranges are the same length, so that can't be the issue.

  13. #13
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: #Value! Error Using SumProduct

    Here are the formulas that OP PM'd me...
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  14. #14
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: #Value! Error Using SumProduct

    edit: OK so both PM's were the same

  15. #15
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    This one is good, I accidentally sent twice, sorry I'm new here lol

  16. #16
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: #Value! Error Using SumProduct

    Have you tried breaking the SP up into 2 parts?
    =SUMPRODUCT(--(DATEVALUE(TEXT(Overall_Pop_Date,"mm/dd/yyyy"))<=$C$43))
    =SUMPRODUCT(--(ISNUMBER(SEARCH("@",Overall_Pop_TPA))

  17. #17
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: #Value! Error Using SumProduct

    Quote Originally Posted by surveyasc View Post
    This one is good, I accidentally sent twice, sorry I'm new here lol
    Not a problem, thought it was 3 more formulas until I posted here

  18. #18
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    hold on please

  19. #19
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: #Value! Error Using SumProduct

    Thanks, Ford, I just got the PM as well, you beat me too it.

    Aside from something in the date column that cannot convert to a valid date, which could be tripping a #Value! error, the only possible thing that I can think of is a discrepancy in the named ranges, which would be tripping a #N/A error. If the formula is returning both, I'm not sure which wouls show first.

    Even though you're sure that both dynamic ranges are the same, with your method, a row that is blank in column M with an entry in column K, or vice versa, would cause an error. I would suggest changing one so that the counts are both done on the same column, as a failsafe, for example.

    =OFFSET('Overall Delivery Population'!$K$2,0,0,COUNTA('Overall Delivery Population'!$M$2:$M$4999),1)

    Although personally, I would use

    ='Overall Delivery Population'!$K$2:INDEX('Overall Delivery Population'!$K$K,Last_Row)

    Where Last_Row is another named range, defined as

    =MATCH("ZZZZ",'Overall Delivery Population'!$M:$M)

    Which would prevent additional possible errors when your table is near full with intermittent blanks. The match should be done in a column where blanks should never occur, using "ZZZZ" as the criteria for text fields, or 1e+100 for numeric.

  20. #20
    Registered User
    Join Date
    06-25-2018
    Location
    Dresher, PA
    MS-Off Ver
    2007
    Posts
    9

    Re: #Value! Error Using SumProduct

    Alright everyone, thank you all for your help! after splitting up the sumproduct like FDibbins had suggested, I saw that the dynamic defined ranges were not lining up like I thought they were supposed to. Although I had the counta() range within the dynamic ranges set to the same distance, they were coming up with different counts due to the different columns they were measuring. I now have each dynamic range set to the same length, and each sum product is working correctly with no error. Thanks again for the help everyone!

  21. #21
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: #Value! Error Using SumProduct

    Please see my last reply with refernce to dynamic named range suggestions.

    Now that you have that resolved, perhaps the countifs suggestion will also work, not knowing the format of the source data it is near impossible to know if the DATEVALUE(TEXT( part of your formulas is necessarry, or if it could be omitted to make the formula more efficient.

  22. #22
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: #Value! Error Using SumProduct

    *^*5 Jason, great teamwork

    Im happy you got where you needed to (splitting a complex formula up, often shows where the error is coming from)

+ 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. Sumproduct with Error #Value!
    By minhtien1900 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-26-2017, 12:05 PM
  2. [SOLVED] SUMPRODUCT #Value error!
    By Berna11 in forum Excel Formulas & Functions
    Replies: 21
    Last Post: 06-09-2017, 05:38 PM
  3. Sumproduct error
    By eisfspike in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 02-14-2017, 12:56 PM
  4. [SOLVED] Sumproduct error
    By Ravana in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-02-2015, 04:42 AM
  5. [SOLVED] Sumproduct - #value error
    By mamachrissy1028 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 05-15-2015, 05:57 PM
  6. Sumproduct-het #VALUE! error.
    By pat55ski in forum Excel General
    Replies: 2
    Last Post: 02-08-2007, 05:13 PM
  7. Error values:DIV/0! error in SumProduct formula with no division
    By Jerry W. Lewis in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-06-2005, 07:05 PM

Tags for this Thread

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