+ Reply to Thread
Results 1 to 8 of 8

Countifs multiple criteria and date has to be >= 15th of the month

  1. #1
    Registered User
    Join Date
    08-16-2022
    Location
    London
    MS-Off Ver
    Newest
    Posts
    3

    Thumbs down Countifs multiple criteria and date has to be >= 15th of the month

    Hi,

    How would I solve this?

    I need to count any rows if they meet multiple criteria, but also the date field has to be greater than or equal to the 15th of the relevant month. E.g. Count if Column labeled contract type says "new build (cash)", and column labeled date of signature is >= 15th of July. Ideally July can 'move' as formula is pulled across each month.

    Please help!

    Capture.PNG

  2. #2
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Countifs multiple criteria and date has to be >= 15th of the month

    Welcome to the forum.

    Assuming your data are in columns A and F, maybe you try something like this:

    =SUMPRODUCT((A2:A100="new build (cash)")*(DAY(F2:F100)>=15))

    If that does not work, please follow instructions on yellow banner abobe to upload a sample wb.

    Good luck!

  3. #3
    Registered User
    Join Date
    08-16-2022
    Location
    London
    MS-Off Ver
    Newest
    Posts
    3

    Re: Countifs multiple criteria and date has to be >= 15th of the month

    Hi!

    I have tried, doesnt quite work I think thats the right idea tho!!

    i cant attach actual document as it is too big, so have made a very simple version. The formula currently does WIP and Cash but need dates to be included for >= 15th of the month. It needs to be dragged to august and still work.

    Please help!!

    Thanks!
    Lois
    Attached Files Attached Files

  4. #4
    Forum Expert
    Join Date
    09-07-2014
    Location
    Israel
    MS-Off Ver
    office 365 for MAC
    Posts
    3,105

    Re: Countifs multiple criteria and date has to be >= 15th of the month

    Hi

    try this in F3:
    =SUM((A3:A38="WIP")*(B3:B38="CASH")*(MONTH(C3:C38)=MONTH(DATEVALUE(F2&"1")))*(DAY(C3:C38)>=15))

    OR

    =COUNT(FILTER($C$3:$C$38,(($A$3:$A$38="WIP")*($B$3:$B$38="CASH")*(MONTH($C$3:$C$38)=MONTH(DATEVALUE(F2&"1")))*(DAY($C$3:$C$38)>=15))))
    Last edited by Limor_OP; 08-16-2022 at 05:44 PM.

  5. #5
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Countifs multiple criteria and date has to be >= 15th of the month

    Another formula option to paste in F3 and copy across:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  6. #6
    Registered User
    Join Date
    08-16-2022
    Location
    London
    MS-Off Ver
    Newest
    Posts
    3

    Re: Countifs multiple criteria and date has to be >= 15th of the month

    Hi, i think this is exactly the formula i need! although i cant get it to work!! I have attached another doc, i have written what I need in red, i would really appreciate it if you could apply your answer above to my example. / even complete it and attach back as I cant get it to work!!

    Thank you!!
    Attached Files Attached Files

  7. #7
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Countifs multiple criteria and date has to be >= 15th of the month

    The date column in your data tab is confusing, as some cells are text instead of numbers (dates).
    To correct that, try selecting the whole range, e.g. H13:H1000, and from the Data ribbon, select Text to Column.
    Then in the dialog box that comes up leave the default option (Delimited) and press Next;
    Uncheck all delimiters and press Next;
    In the last step, select Date (leave MDY selected) and press Finish.

    In the attached wb, to count based on dates smaller then 15, I use this formula in U56, copied across:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    And this one in U57, for dates as 15 and later:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    As the heading in row 46 is not Excel friendly for date reference, in the argument DATE(2021,COLUMNS($A$1:J$1),15) in the formulas above, I use COLUMNS($A$1:J$1), which results 10, the month represented in U46 (Year 2021, as I assume it should be).
    As the formula is copied (dragged) across to V56, the month argument turns into COLUMNS($A$1:K$1) (11=November), then COLUMNS($A$1:L$1) (12=December), then COLUMNS($A$1:M$1) (13=January of 2022), and so on.
    If you have to start count on other column, make sure you change that argument accordingly.

    Please check if this will work for you.
    Attached Files Attached Files

  8. #8
    Forum Expert
    Join Date
    09-07-2014
    Location
    Israel
    MS-Off Ver
    office 365 for MAC
    Posts
    3,105

    Re: Countifs multiple criteria and date has to be >= 15th of the month

    Hi,

    try this:
    AD47:

    Please Login or Register  to view this content.
    AD48:
    Please Login or Register  to view this content.
    Attached Files Attached Files

+ 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. Formula to round date to the next 1st or 15th of month
    By k.a.bekken in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 11-26-2019, 12:23 PM
  2. Replies: 2
    Last Post: 01-06-2019, 12:16 AM
  3. Highlight (Conditional Formatting?) same date (15th) of each month
    By aim85 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-21-2013, 07:24 AM
  4. Formula for IF/THEN EOM and/or 15th of Month based on Today's Date
    By pierzyna in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 06-12-2013, 03:09 PM
  5. [SOLVED] Displaying every 1st and 15th of the month based on todays date
    By sprinter in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 01-03-2013, 12:41 PM
  6. [SOLVED] I want to format date cells for the 15th of every month..
    By Maggie in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-24-2006, 12:15 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