Forum Discussion
Anonymous
8 years agoNot applicable
DAX function for group by.. count
Hello, Need your help! I am writing the following DAX Measure = SUMMARIZE(CrimeDataAnalysisParsed,CrimeDataAnalysisParsed[State],CrimeDataAnalysisParsed[LocalDescription],"MostCrimes",count(C...
- 8 years ago
Hi Anonymous,
SUMMARIZE returns a table rather than value, if you want to use SUMMARIZE fucntion. You need to click "New Table"->under Modeling on Home page, then type the following formula.NewTable =
SUMMARIZE (
CrimeDataAnalysisParsed,
CrimeDataAnalysisParsed[State],
CrimeDataAnalysisParsed[LocalDescription],
"MostCrimes", COUNT ( CrimeDataAnalysisParsed[ID] )
)
Otherwise, if you want to create a measure, please use the following formula, then create a table visual, select CrimeDataAnalysisParsed[State],CrimeDataAnalysisParsed[LocalDescription] and measure as values level to display the result.measure = CALCULATE ( COUNT ( CrimeDataAnalysisParsed[ID] ), ALLEXCEPT ( CrimeDataAnalysisParsed, CrimeDataAnalysisParsed[State], CrimeDataAnalysisParsed[LocalDescription] ) )
Please feel free to ask if you have any other issues.
Best Regards,
Angelia
fduran
7 years agoAdvocate I
Thank you Angelina! This is exactly what I needed to summarize my data in a stats table!