COUNTIF date is this month
I'm trying to create a summary to only total projects that were added to my portfolio this month. I've got this formula to work in excel, but I can't get it to work in smartsheet. For reference, I'm a pro user.
Excel formula:
=COUNTIF(B2:B9,">="&DATE(2022,2,1))
Smartsheet formula:
=COUNTIF({Added to Portfolio},">="&DATE(2022,02,01))
Thoughts?
Answers
-
Hi @Paula D , One approach would be to create a helper column that converts your "Added to Portfolio" date column into the month associated with that date.
Be sure your "Added to Portfolio" column properties is DATE and then in your Helper Column next to it add the formula =MONTH([Added to Portfolio]@row)
You can convert the formula in the "Month Added" Column to a column formula and then hide it so you don't have to actively manage it when new rows are added and to keep your sheet clean.
Your Count if formula would be
=COUNTIF([Month Added]1:[Month Added]11, =MONTH(TODAY()))
Or if you want the month to be static you could just reference the numerical representation of the month. In this example Feb = 2
=COUNTIF([Month Added]1:[Month Added]11, 2)
To select the entire column as the range, remove the numbers at the end of the column name ref.
=COUNTIF([Month Added]:[Month Added], 2)
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 441 Global Discussions
- 140 Industry Talk
- 472 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 496 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!