Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I have use the followin formu;ar Total Revenue LY = Calculate([Total Revenue],SAMEPERIODLASTYEAR(DimDate[Date].[Year])) and get the following error message
Here is part of the error message: 'Calculated Measures'[Total Revenue LY]; A column specified in the call to function " SAMEPRIOD LASTYEAR" is not date type. AM finding this difficult to understand. The Date COlumn is a date ctype. I have tried to use DATEADD , but I still get the same error. I have looked in most discussion , I have not found a solution. Can anyone help.
Solved! Go to Solution.
Hi @ZataConsulting,
Please try again without the ".[Year]" part.
Total Revenue LY = CALCULATE ( [Total Revenue], SAMEPERIODLASTYEAR ( DimDate[Date].[Year]) )
Best Regards,
Dale
Hi @ZataConsulting,
Please try again without the ".[Year]" part.
Total Revenue LY = CALCULATE ( [Total Revenue], SAMEPERIODLASTYEAR ( DimDate[Date].[Year]) )
Best Regards,
Dale
Hi @ZataConsulting,
Please create a date table ( with continuous date) and link it to your "fact" table.
Then you can use these formula to calculate previous period revenue.
We can assist if you have any issues.
Ninter
Total Revenue LY = CALCULATE ( [Total Revenue], SAMEPERIODLASTYEAR ( DimDate[Date].[Year]) )
Thankyou. The solution works.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
97 | |
84 | |
67 | |
60 |
User | Count |
---|---|
150 | |
120 | |
99 | |
87 | |
68 |