Count previous month items
Hi i am creating a metrics for a Dashboard and i just need a count of new items that were created in the previous month. I am using as base the "created date" column. For your reference i already have one that is counting the items created during the current month and it is working. What i don't know if where to include an argument to change to previous month.
This is the formula that i have now for current month count
=COUNTIFS({What is it?}, "Issue", {Created date}, AND(IFERROR(MONTH(@cell), 0) = MONTH(TODAY()), IFERROR(YEAR(@cell), 0) = YEAR(TODAY())))
Best Answer
-
Try this...
=COUNTIFS({What is it?}, "Issue", {Created date}, AND(IFERROR(MONTH(@cell), 0) = IF(MONTH(TODAY()) = 1, 12, MONTH(TODAY()) - 1), IFERROR(YEAR(@cell), 0) = YEAR(TODAY()) - IF(MONTH(TODAY()) = 12, 1)))
Answers
-
Try this...
=COUNTIFS({What is it?}, "Issue", {Created date}, AND(IFERROR(MONTH(@cell), 0) = IF(MONTH(TODAY()) = 1, 12, MONTH(TODAY()) - 1), IFERROR(YEAR(@cell), 0) = YEAR(TODAY()) - IF(MONTH(TODAY()) = 12, 1)))
-
Thanks Paul you are da man!
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 67.2K Get Help
- 452 Global Discussions
- 155 Industry Talk
- 505 Announcements
- 5.4K Ideas & Feature Requests
- 85 Brandfolder
- 156 Just for fun
- 81 Community Job Board
- 514 Show & Tell
- 34 Member Spotlight
- 2 SmartStories
- 308 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!