Counting Opened Opened for a Particular Year
Hello,
I want to count the number of tickets that were opened in 2022. I am getting a invalid date type error message. The date range in the cross reference is restricted to dates only.
=COUNTIF({Date Requested}, YEAR(@cell) = 2022)
Answers
-
Hi @Mallory M.,
YEAR does not seem to play brilliantly with COUNTIF(s), so here's an alternative which should work:
=COUNTIFS({Date requested}, >=DATE(2022, 1, 1), {Date requested}, <=DATE(2022, 12, 31))
Hope this helps, but if you've any problems/questions then just post!
-
If you have blanks and/or non-date values in the date range, it will throw that error from the YEAR function. Try this:
=COUNTIF({Date Requested}, IFERROR(YEAR(@cell), 0) = 2022)
Come see me in Seattle at ENGAGE 2024! I will be at the 10xViz partner booth throughout as well as the "Lets Talk About Community" Meet & Eat table on Tuesday from 11:45am - 12:45pm!
-
@Paul Newcome - That worked thank you so much! If I wanted to change the year to the current year how would I notate that? I tried the following and it did not work - Year@cell),0)=Today())
-
=COUNTIF({Date Requested}, IFERROR(YEAR(@cell), 0) = YEAR(TODAY())) would do the current year.
-
@Nick Korna Thank you!!
-
Happy to help. 👍️
Come see me in Seattle at ENGAGE 2024! I will be at the 10xViz partner booth throughout as well as the "Lets Talk About Community" Meet & Eat table on Tuesday from 11:45am - 12:45pm!
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 63K Get Help
- 380 Global Discussions
- 212 Industry Talk
- 442 Announcements
- 4.6K Ideas & Feature Requests
- 140 Brandfolder
- 129 Just for fun
- 130 Community Job Board
- 449 Show & Tell
- 30 Member Spotlight
- 1 SmartStories
- 305 Events
- 34 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!