Year Function
I have a date column [Updated on]. I a formula to count all the items in the column which occurred in 2021. I have the following so far. I am getting INVALID DATA TYPE.
=COUNTIF([Updated on]:[Updated on], YEAR(@cell) = YEAR(TODAY()))
Best Answers
-
Try this to accommodate blanks and other non-date values:
=COUNTIF([Updated on]:[Updated on], IFERROR(YEAR(@cell), 0) = YEAR(TODAY()))
-
That worked great. Thanks for the help.
Answers
-
Try this to accommodate blanks and other non-date values:
=COUNTIF([Updated on]:[Updated on], IFERROR(YEAR(@cell), 0) = YEAR(TODAY()))
-
That worked great. Thanks for the help.
-
Happy to help. 👍️
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 63.8K Get Help
- 406 Global Discussions
- 218 Industry Talk
- 457 Announcements
- 4.7K Ideas & Feature Requests
- 141 Brandfolder
- 136 Just for fun
- 57 Community Job Board
- 459 Show & Tell
- 31 Member Spotlight
- 1 SmartStories
- 297 Events
- 37 Webinars
- 7.3K Forum Archives
Want to practice working with formulas directly in Smartsheet?
Check out the Formula Handbook template!
Check out the Formula Handbook template!