Forum Discussion
Anonymous
1 year agoNot applicable
RANK by category?
Hello all! Looking for some guidance on how to resolve the following scenario. I have two tables: FACTS RecordID (number) BusinessUnit (text) ReportNum (text) CODES TABLE Code (te...
- Anonymous1 year ago
Sorry for so many replies! I figured out that this is working as long as I have all of the data in one table. I wasn't sure how to rank the count of codes, where the codes were in the "many" table of the one-many relationship between my facts table and my code table. What I ended up doing was adding a new calculated column into my CODES table to pull the name of the BusinessUnit in using the RELATED calculation. Now if I perform my ranking all in one table (the CODES table) it's working fine. I'm still curious how this would be able to work, however, using both tables!
Anonymous
1 year agoNot applicable
Yes, I have a measure called "CodeCount":
CodeCount = COUNT('Codes'[ReportNum])
My rank:
CodeRank = RANKX(ALL('Codes'[Code]),Measures_Table[CodeCount])
When I use the CodeRank to filter the visual (CodeRank<6) it doesn't actually filter anything under the BusinessUnit. I get all of the counts for all of the codes under each BusinessUnit. I have tried different rank measures, but can't seem to get it right.
Anonymous
1 year agoNot applicable
OK the count is working, my Rank shows up with ranking 1 for each BusinessUnit 'Code'.