+ Reply to Thread
Results 1 to 6 of 6

SUM Data Between 2 Dates

  1. #1
    Registered User
    Join Date
    04-11-2008
    Posts
    17

    Angry SUM Data Between 2 Dates

    Okay now lets say 'Transaction DB'J:J contains the dates we are searching against. $A contains the Product ID Number and 'Transaction DB'AD:AD contains the total that needs to be summed.

    I want to pull information between 10/1/2009 thru 10/31/2009 that match Item Number (from $A on same sheet) to sum the Totals in 'Transaction DB'AD:AD that match all criteria above.

    What I've been trying to use:
    {=SUMPRODUCT(‐‐('Transaction DB'!J:J,">="&DATE('Set Date'!$D$2,'Set Date'!$B$2,'Set Date'!$C$2)),‐‐('Transaction DB'!J:J,"<="&DATE('Set Date'!$D$4,'Set Date'!$B$4,'Set Date'!$C$4)),--('Transaction DB'!D:D,A5),('Transaction DB'!$AD:$AD))}

    I get:
    #NAME?

    What gives?
    Last edited by TRI0N; 11-19-2009 at 07:46 PM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: SUM Data Between 2 Dates

    If your are using XL2007, then

    Please Login or Register  to view this content.
    otherwise you need defined ranges, not whole ranges...

    e.g

    Please Login or Register  to view this content.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: SUM Data Between 2 Dates

    Hi,

    You can't use whole column references with SUMPRODUCT(). You need to specify the A1 type address. e.g.

    Please Login or Register  to view this content.
    and keep the range to just the data since these array functions are heavy on processing and take exponentially longer as the number of rows increases. Make sure all the ranges are of a consistent length. i.e. J2:J100 & AD2:AD100 not AD2:AD101 or something else.

    HTH
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    Registered User
    Join Date
    04-11-2008
    Posts
    17

    Re: SUM Data Between 2 Dates

    I'm using 2007 of course..

  5. #5
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: SUM Data Between 2 Dates

    Quote Originally Posted by daddylonglegs View Post

    I use specific ranges, you can only use whole columns in SUMPRODUCT if you are using Excel 2007......
    Thanks ddl. I didn't know that had changed for 2007. Another one to file away.

    Cheers.

  6. #6
    Registered User
    Join Date
    01-06-2008
    Posts
    19

    RE: SUM Data Between 2 Dates

    Can you please put the formula in the excel file and provide me with the file? It doesn't seem to work for me.

+ 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