Group by a Category and then Rank - Power BI
community.powerbi.com › t5 › Power-QueryJun 30, 2021 · I have the following table of data that I would like to Group by the Category column and then create a rank based on the number of occurrences (Accounts) within each Category. To go further - I will need to create a Pie Chart that shows the Top 3 Categories with the most Accounts. All help is appreciated! Data table is named - CoolSports. ACCOUNT.
Group multiple columns and rank within the group power query
stackoverflow.com › questions › 73086762Jul 22, 2022 · RankGroup = (UnRanked as table, GroupFields as list, RankFields as list, RankNames as list) as table => let //Group by GroupFields Grouped = Table.Group (UnRanked, GroupFields, { {"Ranked", each _}}), // Ranks Subfunction Ranks = (InVal as table, NewCols as list, Fields as list) as any => let // Soon to be replaceable Rank Function Rank = (InVal …
Solved: Advanced Rank in Power Query - Microsoft Power BI ...
community.powerbi.com › t5 › DesktopNov 14, 2021 · step1,group and add inex: = Table.Group (Source, {"Date"}, { {"Partition", each Table.AddIndexColumn (_, "Ranking",1,1), type table}}) Step2, expand table: = Table.ExpandTableColumn (Partition, "Partition", {"Index", "Ranking"}, {"Index", "Ranking"}) All power query: