Forum Discussion
JohanKnape
9 years agoRegular Visitor
Total count that month
I'm trying to get a total count of all the rows and show the increase or decline each month. Tried some of the examples here with running totals etc but can't make it work. I don't have a sum, bu...
Anonymous
9 years agoNot applicable
Hi JohanKnape,
According to your description, you want to get the rows count of current month, right?
If this is a case, you can try to use below formula if it suitable for your requirement.
Measures:
Count Of Current Month =
var currDate=MAX([Date])
Return
COUNTX(FILTER(ALL('Date Table'),YEAR([Date])=YEAR(currDate)&&MONTH([Date])=MONTH(currDate)),[Date])
Count Of Previous Month =
var currDate=MAX([Date])
Return
COUNTX(FILTER(ALL('Date Table'),[Date]>=DATE(YEAR(currDate),MONTH(currDate)-1,1)&&[Date]<=DATE(YEAR(currDate),MONTH(currDate),1)-1),[Date])
Increase=[Count Of Current Month] - [Count Of Previous Month]
Regards,
Xiaoxin Sheng
JohanKnape
9 years agoRegular Visitor
Hi, did a fast try of your examples but didn't get it to work.
Will try again this afternoon when I have more time and hopefully get it right.