Forum Discussion
Kaddrik
Mar 16, 2022Copper Contributor
Count the number of dates based on a condition
Hello, hope you are doing good. I have a pivot table with dates in a column. Using conditional formating i set the dates that are between today and up to 329 away as green , those that betwee...
- Mar 16, 2022
Green:
=COUNTIFS(H:H,">"&TODAY()-329,H:H,"<="&TODAY())
Orange:
=COUNTIFS(H:H,">"&TODAY()-365,H:H,"<="&TODAY()-330)
Red:
=COUNTIFS(H:H,">0",H:H,"<="&TODAY()-365)
HansVogelaar
Mar 16, 2022MVP
Green:
=COUNTIFS(H:H,">"&TODAY()-329,H:H,"<="&TODAY())
Orange:
=COUNTIFS(H:H,">"&TODAY()-365,H:H,"<="&TODAY()-330)
Red:
=COUNTIFS(H:H,">0",H:H,"<="&TODAY()-365)
- KaddrikMar 16, 2022Copper ContributorHello HansVogelaar
Thanks a lot for your reply.
oooh nice !! it seems to be working... well it takes some additional values those H1 to H18 and some at the end when i filter but i least i get a number that is closer to what i should have.
I guess i could solve this by adding values to range "H:H".
I will see but it's already a very good point 🙂
Thanks a lot !!- HansVogelaarMar 16, 2022MVP
You could change H:H to the relevant part, for example H19:H100. The formulas will be more efficient too.