Forum Discussion
Anonymous
3 years agoNot applicable
Issue with measures
Hi i am new to Power BI Total Sales (Latest Year) = CALCULATE( SUM(Sale[SalesAmount]), FILTER('Sale', 'Sale'[Date].[Year] = [Latest Year]) ) i have this measure which is suppose to calculate sales ...
- 3 years ago
Anonymous- Please check this out, let me know if this works. If this fix your problem, please tick this a solution and a thumps up.
Total Sales (Latest Year) = VAR CurrentYear = MAX('Sale'[Date].[Year]) RETURN CALCULATE( SUM('Sale'[SalesAmount]), FILTER('Sale', YEAR('Sale'[Date]) = CurrentYear) )I've hypothetically established this DAX measure, but without much clarity regarding your datasets. If this doesn't serve your needs, I recommend you share a sample dataset. This will give me a more comprehensive understanding of your data structure, enabling me to devise a more suitable solution.
rsureshkumar98
3 years agoRegular Visitor
Hi Wallet Masster,
You can use below DAX
Total Sales = CALCULATE(SUM(Sales([SalesAmount]),FILTER(YEAR(TODAY())-1)
Let me know if this works
Anonymous
3 years agoNot applicable
This works too thanks