Forum Discussion
Anonymous
3 years agoNot applicable
GROUP BY expression as a measure
Hello smart people! I have a data like this: And need to build a chart which will show how many books on average each player had daily. So I am trying to get (what should be) a fairly simple...
- 3 years ago
Hi Anonymous ,
Please follow these steps:
(1) Create a new measure
AVG = DISTINCTCOUNT('Table'[book_id])/DISTINCTCOUNT('Table'[user_id])(2)Final output
Best Regards,
Gallen Luo
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
v-jialluo-msft
Community Support
3 years agoHi Anonymous ,
Please follow these steps:
(1) Create new measures
BOOK BY GROUP = CALCULATE(DISTINCTCOUNT('Table'[book_ id]),FILTER(ALL('Table'),'Table'[group] = MAX('Table'[group])))
BOOK BY USER = CALCULATE(DISTINCTCOUNT('Table'[book_ id]),FILTER(ALL('Table'),'Table'[user_ id] = MAX('Table'[user_ id])))
(2)Final output
If that's not what you need, please give sample files and expected output.
Best Regards,
Gallen Luo
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.