Forum Discussion
vmurali1
3 years agoFrequent Visitor
Requesting help with DAX Calculation
Team, I have a matrix where i am trying to calculate cost per case. The formula for that would be - Total Product Cost / Total# of Cases. I created two measures. One to sum the total product cost a...
- Anonymous3 years ago
Hello vmurali1 if you want the #cases to be constant by year, you can try to first create a new column year with formula
Year= YEAR(table[case date])
Then create a new measure
# cases by year = Calculate(distinctcount[column you want],allexcept(table,table[Year]))
- Anonymous3 years ago
If you want the # cases by year according to column "name" then just do
# cases by year = Calculate(count(table[name],allexcept(table,table[Year],table[name]))
vmurali1
3 years agoFrequent Visitor
Thank you for the response but, i want the number of cases to be constant by name (first col) and year.
Anonymous
3 years agoNot applicable
If you want the # cases by year according to column "name" then just do
# cases by year = Calculate(count(table[name],allexcept(table,table[Year],table[name]))