Formula to Count Data Broken Down by Month
I am wanting to use a formula to count data in various columns based on specific time period. Example for the month of October, I would like to count various column data and when it rolls into November I would like the formula to continue to work without changing it.
I am able to use my formula (see below) to capture exactly what I need between 9/30/19 and 11/1/19 but it seems that my current approach to this will require to me to go into the formulas for each calculation at the start of the next month and modify. My hopes are that there is an easier way to approach this.
Formula (gives me what I need):
=COUNTIFS([Date of RMA Request]:[Date of RMA Request], >DATE(2019, 9, 30), [Date of RMA Request]:[Date of RMA Request], <DATE(2019, 11, 1), [RMA Type Code]:[RMA Type Code], "28-Site Survey Error")
Comments
-
Thank you for the insight- will this formula allow for the metric to maintain current month count?
Another words, when we roll into November will it continue to count November?
-
No it will not. The 10 is the month number you are looking for (same with 2019 being the year number), so replacing those values with functions to automate those numbers is what you are going to need to do.
MONTH(TODAY())
YEAR(TODAY())
Put those in place of the month and year numbers, and the formula will automatically look for the current month.
-
Thank you Paul. I am going to try it today and see what I get.
-
-
Any idea what I am missing here? This is what I have in and I am getting #UNPARSEABLE error message
=COUNTIFS([Date of RMA Request]:[Date of RMA Request], AND(IFERROR MONTH(TODAY()), IFERROR(YEAR(TODAY()), [RMA Type Code]:[RMA Type Code], "28-Site Survey Error")
-
You aren't finishing out the logical statements or IFERROR functions within your AND statement which in turn has left your AND statement open.
.
Take my previously posted formula and replace the number 10 and the number 2019 with
MONTH(TODAY())
and
YEAR(TODAY())
respectively.
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 64.1K Get Help
- 414 Global Discussions
- 221 Industry Talk
- 461 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 141 Just for fun
- 58 Community Job Board
- 462 Show & Tell
- 32 Member Spotlight
- 1 SmartStories
- 299 Events
- 38 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!