Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi Everyone,
I am hoping this is simple for someone here but I have been having a devil of a time getting the result I need.
Here is my table
I want a new column that I will call Nr in EG that counts the number of distinct schools numbers within an enrollmen group so the results would look like this
SchNr | Enrollment Groups | Nr in EG |
15 | <100 | 1 |
110 | 201-350 | 2 |
123 | >350 | 2 |
134 | 100-200 | 1 |
163 | 201-350 | 2 |
167 | >350 | 2 |
I have measures that give me this count for each enrollment group already but I need a single column that tells me the total number of schools so next to a school i can see the number of schools that are in the same enrolment group.
Any assitance would be greatly appreciated.
Thanks
Kyle
Edit: Corrected expected output
Solved! Go to Solution.
@juncco888 add column using following DAX:
Count = CALCULATE ( COUNT ( School[SchNr] ), ALLEXCEPT ( School, School[Enrollment Groups] ) )
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@juncco888 add column using following DAX:
Count = CALCULATE ( COUNT ( School[SchNr] ), ALLEXCEPT ( School, School[Enrollment Groups] ) )
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Thanks so much.... AllExcept is what I was missing..... I am going to read up on AllExcept because my guess is it will solve many problems for me. I really appreciate it....
@juncco888 isn't the last row the value supposed to be 2?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Yes... it is ... I will corrrect that,... Thanks for pointing that out
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
63 | |
63 | |
53 | |
39 | |
25 |
User | Count |
---|---|
85 | |
57 | |
45 | |
43 | |
38 |