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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Pbiuserr
Post Prodigy
Post Prodigy

TOP N for a chart with two values

Hello,

I have value Sales Amount and Sales Amount LY in a chart (made out of field parameter, 5 dimensions) and I created a TOPN slicer alike in this video youtube.com/watch?v=SsZseKOgrWQ 

It works, but because I have two measures in values, it indeed filter Sales Amount, but they it also displays whatever category has Sales Amount LY. Is there anything I can do to just see TOP N of Sales Amount and if its selected, dont mind LY (just corresponding LY to TOP N values?)

 

Pbiuserr_0-1661249510536.png

 

2 REPLIES 2
amitchandak
Super User
Super User

@Pbiuserr , create both TOPN on one measure. refer example , and calculate other measure on that

 

example

 

CALCULATE( [MTD Sales] ,TOPN(3,allselected('Table'[Category]),[MTD Sales],DESC),values('Table'[Category]))


CALCULATE( [last MTD Sales] ,TOPN(3,allselected('Table'[Category]), [MTD Sales] ,DESC),values('Table'[Category]))

How to display then a full view?

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.