Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi All,
I am new to PowerBI and cannot seem to get the TotalMTD formula to work in a new Measure. I read the other posts but no matter what I do the formula does do as intended. I have used dates within the existing report as well as using a linked date report. Is there a certain date format that I should be following?
MTD Collections = TOTALMTD(SUM(Reciepts[Amount Received]),Reciepts[Date]); and
MTD Collections = TOTALMTD(SUM(Reciepts[Amount Received]),'Datekey'[Date]).
Both sets of dates are formatted as (yyyy/MM/dd)
Thanks in advance for your assistance.
Regards,
Bruce
Solved! Go to Solution.
Hi @bjones,
As you mentioned in original post, the date is 'yyyy/MM/dd' format. But from the screenshots, it seems that you display date hierarchy instead of date value so the TOTALMDT is not working. In your scenario, you need to display date value in the table, then change aggregate function for the [Matter no count] as SUM, then create the measure like below:
MTD_Arrangements=TOTALMTD(SUM('Fixed arrangement'[Matter no count]),'Datekey'[Date])
If you have any question, please feel free to ask.
Best Regards,
Qiuyun Yu
Any chance you can post some sample data, your result and the expected result?
I'll have to try it with yyyy/MM/dd but generally I have my dates in dd/MM/yyyy.
Hi Smoupre,
I have moved on to a new data set but the formulas remain the same in principle. ONe fgives me the sum per day and the other returns the mtd total in each day as opposed to the cumulative total in each day. I need it to return the below data set.
I hope that this is clear.
Cheers,,
Bruce
Hi @bjones,
As you mentioned in original post, the date is 'yyyy/MM/dd' format. But from the screenshots, it seems that you display date hierarchy instead of date value so the TOTALMDT is not working. In your scenario, you need to display date value in the table, then change aggregate function for the [Matter no count] as SUM, then create the measure like below:
MTD_Arrangements=TOTALMTD(SUM('Fixed arrangement'[Matter no count]),'Datekey'[Date])
If you have any question, please feel free to ask.
Best Regards,
Qiuyun Yu
looking at your last table; it does not actually seem like a MTD because those are not dates but rather a cumulative running total:
Running = SUMX(
FILTER('Fixed Arrangement',
'Fixed Arrangement'[Column1]<=EARLIER('Fixed Arrangement'[Column1])
),
'Fixed Arrangement'[Column2])
.... assuming that 'Fixed Arrangement' is the table name; then I used 'column1' and 'column2' rather than what I see as your actual column names since they seem to change by table ....so you can use whichever is right for you.....
User | Count |
---|---|
140 | |
113 | |
104 | |
77 | |
64 |
User | Count |
---|---|
135 | |
122 | |
101 | |
71 | |
61 |