Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.
Hi.
I have created 2 measures using same formula, but one of my DAX is not working and other is working fine.
I have attached screenshots of the same.
Solved! Go to Solution.
@SanketBhagwat
So you need the year with the highest value:
Qualification =
MAXX(
TOPN (
1,
ALLSELECTED (WC_YEARS[YEAR]),
[Highest Qualification]
),
WC_YEARS[YEAR]
)
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
The 2nd screenshot doesn't show the Qualification measure, you need to clear on it and share the screenshot.
You use ALLSELECTED(WC_Years[Year]) instead of GROUP BY
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
You are getting this error because the TOPN function is returning multiple values. There are multiple years for which the value is equal to Highest Qualifications.
Hi @Fowmy @Anonymous
I just noticed that there are multiple year values for which the 'Highest Qualifications' measure is giving the same value.
Do you guys know any DAX which will return only 1 year value.
@SanketBhagwat
You can use MAXX
Attendnace =
MAXX (
VALUES(WC_YEARS[YEAR]),
[Highest Attendance]
)
Qualification =
MAXX (
VALUES(WC_YEARS[YEAR]),
[Highest Qualification]
)
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
Sorry, but the solution you provided didn't gave the correct answer.
@SanketBhagwat
So you need the year with the highest value:
Qualification =
MAXX(
TOPN (
1,
ALLSELECTED (WC_YEARS[YEAR]),
[Highest Qualification]
),
WC_YEARS[YEAR]
)
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 3 | |
| 3 | |
| 3 |
| User | Count |
|---|---|
| 11 | |
| 9 | |
| 8 | |
| 7 | |
| 6 |