+ Reply to Thread
Results 1 to 5 of 5

SumProduct By Month with #N/A Problem

  1. #1
    Registered User
    Join Date
    05-29-2009
    Location
    Indianpolis USA
    MS-Off Ver
    Excel 2010
    Posts
    14

    SumProduct By Month with #N/A Problem

    I need a little help to finish this out, this below works fine as long as I don't have any #N/A (theses are Formulas #N/A). I'm not sure what to place to ignore the #N/A and just bring back the the info I need.

    What I'm doing with this is take the date the customer made an order that month and seeing the average of how many days it took in that month to get the order shipped.

    I have seen iserror and other ones but I'm not sure how to place this and still get it to work. This is what I have so far.

    =SUMPRODUCT(--(MONTH($D$9:$D$698)=4),$J$9:$J$698)/SUMPRODUCT(--(MONTH($D$9:$D$698)=4))

    Thanks ahead for anyone who spends any time on this!
    Travis

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: SumProduct By Month with #N/A Problem

    Can you post the formulas that are creating the N/A# errors in your sheet? The best solution would involve solving THOSE errors so your sumproduct() formula can work.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: SumProduct By Month with #N/A Problem

    Ignoring issues of #N/A it might make sense to switch to an AVERAGE Array rather than 2 Sumproducts:

    =AVERAGE(IF(MONTH($D$9:$D$698)=4,$J$9:$J$698))
    committed with CTRL + SHIFT + ENTER

    if the NAs are in J you could use:

    =AVERAGE(IF((MONTH($D$9:$D$698)=4)*(ISNUMBER($J$9:$J$698)),$J$9:$J$698))
    committed with CTRL + SHIFT + ENTER
    (can adapt for D if necessary)

    but as JB states always better to fix the issue at source - ie resolve NA's wherever they are appearing.

  4. #4
    Registered User
    Join Date
    05-29-2009
    Location
    Indianpolis USA
    MS-Off Ver
    Excel 2010
    Posts
    14

    Re: SumProduct By Month with #N/A Problem

    The #N/A are items that have not shipped yet and is pulling from an index array. I pull info out of our company system in a paste into different tabs and I have all this pulled into one tab. This is do I can update the tabs with a simple copy paste. And this will update the main tab. I will always have some #N/A.

  5. #5
    Registered User
    Join Date
    05-29-2009
    Location
    Indianpolis USA
    MS-Off Ver
    Excel 2010
    Posts
    14

    Re: SumProduct By Month with #N/A Problem

    Thanks DonkeyOte, that looks like it worked!

+ 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