Forum Discussion
Currenmonth and Previous Month values along with comments
Hi chlimaye ,
I suggest you to create a dimdate table with continuous date and then use datetime intelligence function:
submissionDate = ADDCOLUMNS(CALENDAR(DATE(2024,1,01),DATE(2024,12,31)),"Sub Month",FORMAT([Date],"YYYY-MM"),"YearMonth",YEAR([Date])*100 + MONTH([Date]))
Relationship:
Measures:
M_Volume = CALCULATE(SUM('Table'[Volume]))Previous Volume = CALCULATE([M_Volume],PREVIOUSMONTH(submissionDate[Date]))Curre- PreviousMonth Diff = [M_Volume] - [Previous Volume]
Result is as below.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- chlimaye1 year agoRegular Visitor
it giving me same output.
- chlimaye1 year agoRegular Visitor
got same result.
- Anonymous1 year agoNot applicable
Hi chlimaye ,
Please make sure there is continuous date in your dimdate table or datetime intelligence function will not work.
I think your issue is based on your data model. You can download my attatchment file before and compare mine with yours.
If this still couldn't help you solve your issue. Please share a sample file with us and show us a screenshot with the result you want. This will make it easier to find the solution.
Best Regards,
Rico ZhouIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.