google-sheetsgoogle-sheets-formulacountif

COUNTIFS WITHIN DATE RANGE GOOGLE SHEET


I need to get the count of my NOTICE SENT weekly. I have updated as of date to identify the week I need in the report.

FORMULA:

=COUNTIFS($B$3:$B$8,$F$2,$C$3:$C$8,$F3,$D$3:$D$8,">="&$B$1,$D$3:$D$8,"<="&$B$1-6)

Link Sheet Here:


Solution

  • Use QUERY() function like-

    =QUERY(B3:D,"select C, count(B) where B='" & F2 & "' and D>= date '" &TEXT(B1-6,"yyyy-mm-dd")& "' and D<= date '" & TEXT(B1,"yyyy-mm-dd")& "' group by C label count(B) ''")
    

    Or COUNITIFS()-

    =COUNTIFS($B$3:$B$8,$F$2,$C$3:$C$8,$F3,$D$3:$D$8,">="&$B$1-6,$D$3:$D$8,"<="&$B$1)
    

    enter image description here