Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join 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.

Reply
Thakshila
Frequent Visitor

issue when getting the nth value with DAX query for sub categories


I'm trying to get the nth value using below dataset. I could get the nth value for the correct category. When I added the sub category. It gives the wrong result for the sub categories. It takes the nth value for the sub categories as well. how to avoid this and get the correct result for the sub categories as well. I have attached my .PBI file and pictures of my dax query and results as well.
(https://1drv.ms/u/s!AtRjTEx4ATvZykgX9eSCVl0xBFXa?e=Fz2ctR )
Any help would be appriciated. 
Please check the below screen shot. 


Dax Query
pbi2.PNG

 

Results    

PBI1.PNG

 

1 ACCEPTED SOLUTION
wdx223_Daniel
Super User
Super User

1 REPLY 1
wdx223_Daniel
Super User
Super User

wdx223_Daniel_0-1616662220051.png

 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.