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
SteveIOW
Helper II
Helper II

display text value associated with a calculated value

Good morning,

 

I am totally stuck!

 

I have a table of values for which I have created a measure.

SteveIOW_0-1652455066137.png

 

 

 

what I need to do is to create a new measure such that it returns only the worst performer.

i.e. Measure = "ModalityValue" where Value = Worst(Min) Value".

in the example above I would want it to return "Non-Obstetric Ultrasound".

 

Does anyone have any ideas please?

 

Kind regards

Steve

 

PS the measure value 94K is created from

VariationActAv min per Modality =

MINX(

    KEEPFILTERS(VALUES('Modalities'[Modality])),

    CALCULATE([VariationActAv])

)

 

 

1 ACCEPTED SOLUTION
SpartaBI
Community Champion
Community Champion

@SteveIOW 

TOPN(1, VALUES(Modalities[Modality]), [VariationActAv]ASC)
 I guess [VariationActAv] is a measure so we don't need a calculate around it.
In case you only have 1 value it will transform this table result into a scalar value and you could put it in a card visual. In case there is a tie in the 1st place this measure will break. You can wrap it up with CONCATENATEX and decide how you want to present it.


P.S. In the measure you wrote, you don't need KEEPFILTERS on top of VALUES, becasue VALUES already keeping all the filters, and you also didn't need to write calculate as a measure reference already get's an implicit calculate around it.


2022-05-09 22_36_04-Power BI Workspace Datasets License Permissions - Microsoft Power BI Community.png

Showcase Report – Contoso By SpartaBI


SpartaBI_3-1652115470761.png  SpartaBI_1-1652115142093.png   SpartaBI_2-1652115154505.png

Full-Logo11.png

View solution in original post

3 REPLIES 3
SpartaBI
Community Champion
Community Champion

@SteveIOW 

TOPN(1, VALUES(Modalities[Modality]), [VariationActAv]ASC)
 I guess [VariationActAv] is a measure so we don't need a calculate around it.
In case you only have 1 value it will transform this table result into a scalar value and you could put it in a card visual. In case there is a tie in the 1st place this measure will break. You can wrap it up with CONCATENATEX and decide how you want to present it.


P.S. In the measure you wrote, you don't need KEEPFILTERS on top of VALUES, becasue VALUES already keeping all the filters, and you also didn't need to write calculate as a measure reference already get's an implicit calculate around it.


2022-05-09 22_36_04-Power BI Workspace Datasets License Permissions - Microsoft Power BI Community.png

Showcase Report – Contoso By SpartaBI


SpartaBI_3-1652115470761.png  SpartaBI_1-1652115142093.png   SpartaBI_2-1652115154505.png

Full-Logo11.png

Perfect - thank you so much - and thank you for the tips.

@SteveIOW my pleasure 🙂

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.