+ Reply to Thread
Results 1 to 7 of 7

SUMIFS with date written in formula

  1. #1
    Forum Contributor
    Join Date
    11-04-2015
    Location
    Copenhagen, Denmark
    MS-Off Ver
    2010
    Posts
    114

    SUMIFS with date written in formula

    I have a worksheet with a annual daily dates horizontally.

    Past this I want to have 12 columns that add the data from each date into a monthly overview; a poor man's pivot if you will.

    I figure I will use the SUMIFS with a date range for the 12 months:

    =+SUMIFS(W7:NW7,W6:NW6,"<=1/1/2018",W6:NW6,">=1/31/2018")

    Question: How do I enter the date properly so that it will do the addition? My tests are not working.

    If there is a better way than SUMIFS please let me know.

  2. #2
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,914

    Re: SUMIFS with date written in formula

    Use "<="&date(2018,1,1) instead of "<=1/1/2018"
    and use ">="&date(2018,1,31) instead of">=1/31/2018"
    Samba

    Say thanks to those who have helped you by clicking Add Reputation star.

  3. #3
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,064

    Re: SUMIFS with date written in formula

    Are your sure your condition is correct? <=1/1/2018 AND >=1/31/2018 ??? So any date EXCEPT JAN 2018 ???
    Shouldnt this be >=1/1/2018 AND <=1/31/2018 ???

    Decide what the condition should be and try

    =SUMPRODUCT((W6:NW6<=1/1/2018")*(W6:NW6>1/31/2018")*(W7:NW7))
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  4. #4
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,914

    Re: SUMIFS with date written in formula

    I think it would be
    ">="&date(2018,1,1) and "<="&date(2018,1,31)

  5. #5
    Forum Expert
    Join Date
    11-22-2016
    Location
    Cornwall,UK
    MS-Off Ver
    office 365
    Posts
    4,240

    Re: SUMIFS with date written in formula

    Please attach a workbook to your reply so that we can see exactly what you are trying to do etc
    Ensure the workbook shows the "before" and "after" position


    Attachment 527020
    Attached Images Attached Images
    Last edited by kev_; 07-10-2017 at 06:02 AM.
    Click *Add Reputation to thank those who helped you. Ask if anything is not clear

  6. #6
    Forum Guru xlnitwit's Avatar
    Join Date
    06-27-2016
    Location
    London
    MS-Off Ver
    Windows: 2010; Mac: 16.13 (O365)
    Posts
    7,085

    Re: SUMIFS with date written in formula

    Hi,

    Rather than a "poor man's pivot", why not an actual pivot?

    If you must use SUMIFS, I would suggest
    =SUMIFS(W7:NW7,W6:NW6,">="&DATE(2018,1,1),W6:NW6,"<"&DATE(2018,2,1))
    Note the change to the greater than and less than criteria order.
    Don
    Please remember to mark your thread 'Solved' when appropriate.

  7. #7
    Forum Contributor
    Join Date
    11-04-2015
    Location
    Copenhagen, Denmark
    MS-Off Ver
    2010
    Posts
    114

    Re: SUMIFS with date written in formula

    You are correct Special-K! I switched the signs...

    Thanks nflsales...that worked

+ 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] Change written date format to standard UK date
    By BillDoor in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-17-2015, 03:14 PM
  2. [SOLVED] Sumifs formula without menu typing date
    By bambi ang in forum Excel General
    Replies: 2
    Last Post: 05-28-2014, 06:13 AM
  3. [SOLVED] How to Add a Date Range into an Existing SUMIFS Formula?
    By garrett.grillo in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-03-2014, 03:38 PM
  4. [SOLVED] Sumifs Date Range Formula
    By robbiedew101 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-11-2013, 03:51 PM
  5. Convert Long Written Excel Date to Proper Date
    By DavidMichaelangelo in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 03-19-2013, 04:47 PM
  6. sumifs formula with > operator on a date variable
    By Kaigi in forum Excel General
    Replies: 1
    Last Post: 02-01-2011, 06:46 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