Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hello experts,
I want to retrieve the nb_conv_int for the last month so I used PREVIOUS MONTH as you can see below:
Nb_conv M-1:=CALCULATE([Nb_conv_inter];PREVIOUSMONTH(Date_table[Date]))
But, it returns blank value:
I don't know what's going wrong. Here is my data (if you want to help)
Below my data model:
Thanks in advance.
Solved! Go to Solution.
Hi @FranckGbadamass ,
In order to use any time intelligence calculation, you need a well-formed date table. The Date table must satisfy the following requirements:
The result of time intelligence functions has the same data lineage as the date column or table provided as an argument.
Note: The result table includes only dates that exist in the dates column.
Please check your Date column, or use something to replace the PREVIOUSMONTH fumction:
Nb_conv M-1 = CALCULATE([Nb_conv_inter],Filter('Date_table',[Date]<=EOMONTH(MAX('Date_table'[Date]),-1)&&[Date]>=EOMONTH(MAX('Date_table'[Date]),-2)+1))
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I wouldn't use PREVIOUSMOTH as it does not work the way people would expect it to. Instead, use a different function, DATEADD, that does work the way you'd expect. If you want to know how the functions differ, please go to https://dax.guide/previousmonth and https://dax.guide/dateadd and see the examples there (they're interactive).
Hi @FranckGbadamass ,
In order to use any time intelligence calculation, you need a well-formed date table. The Date table must satisfy the following requirements:
The result of time intelligence functions has the same data lineage as the date column or table provided as an argument.
Note: The result table includes only dates that exist in the dates column.
Please check your Date column, or use something to replace the PREVIOUSMONTH fumction:
Nb_conv M-1 = CALCULATE([Nb_conv_inter],Filter('Date_table',[Date]<=EOMONTH(MAX('Date_table'[Date]),-1)&&[Date]>=EOMONTH(MAX('Date_table'[Date]),-2)+1))
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Check out the September 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
25 | |
20 | |
18 | |
18 | |
15 |
User | Count |
---|---|
36 | |
19 | |
19 | |
17 | |
11 |