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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
hobosapien
Helper I
Helper I

Value from measure not displaying correctly in card visual

I have the following data set. I am trying to pull the name of the person with the highest adherence. When I place it in a card visual it shows a list of concatenated names. How do I get the measure to produce only one name?

hobosapien_0-1737318249969.png

 

Agent MAX Adherence = 
VAR MaxAdherence =
    TOPN( 1 , 'f_Call Metrics', 'f_Call Metrics'[Adherence %])
RETURN
    CONCATENATEX(MaxAdherence, 'f_Call Metrics'[Agent])

 

 

AgentDateAdherence %
Jocelyn Vazquez1/18/20240.976
Jocelyn Vazquez1/24/20240.94
Jocelyn Vazquez1/25/20240.972
Jocelyn Vazquez1/30/20240.972
Jocelyn Vazquez1/31/20240.989
Isaias Wiggins3/18/20240.957
Isaias Wiggins3/25/20240.96
Isaias Wiggins4/3/20240.976
Isaias Wiggins4/19/20240.885
Isaias Wiggins5/3/20240.917
Donovan Christian5/8/20240.926
Donovan Christian5/23/20240.891
Donovan Christian5/31/20240.928
Donovan Christian8/2/20240.843
Donovan Christian8/22/20240.903
Rafael Beck8/19/20240.964
Rafael Beck10/31/20241
Shiloh Anderson1/2/20240.963
Shiloh Anderson1/9/20240.965
Shiloh Anderson1/11/20240.944
Shiloh Anderson1/12/20240.973
Shiloh Anderson1/17/20240.966
5 REPLIES 5
Anonymous
Not applicable

Hi @hobosapien ,

 

Thank you for your interest in this case.

 

Using your syntax works fine for me and I cannot reproduce your error. I think the error may be in the fact that the CONCATENATEX function concatenates more than one name instead of extracting just one.

CONCATENATEX function (DAX) - DAX | Microsoft Learn

 

Try another syntax, this works fine.

Agent_MAX_Adherence = 
VAR MaxAdherence =
    MAXX('f_Call Metrics', 'f_Call Metrics'[Adherence %])
VAR TopAgent =
    FILTER(
        'f_Call Metrics',
        'f_Call Metrics'[Adherence %] = MaxAdherence
    )
RETURN
    MAXX(TopAgent, 'f_Call Metrics'[Agent])

vhuijieymsft_0-1737439848223.png

 

The pbix file is attached.

 

If you have any other questions please feel free to contact me.

 

Best Regards,
Yang
Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

ThxAlot
Super User
Super User

  1. Hover the mouse over the funnel icon to see what underlying filters are,
    ThxAlot_0-1737362653400.png

     

  2. Your measure might work correctly in most cases, but can't handel a dataset with duplicated max metrics,
    AgentDateAdherence %
    Jocelyn Vazquez 1/31/2024 0.989
    Isaias Wiggins 3/18/2024 0.957
    Isaias Wiggins 3/25/2024 0.96
    Isaias Wiggins 4/3/2024 0.976
    Isaias Wiggins 4/19/2024 0.885
    Donovan Christian 8/2/2024 0.843
    Donovan Christian 8/22/2024 0.903
    Rafael Beck 8/19/2024 0.964
    Rafael Beck 10/31/2024 1
    Rafael Beck 10/31/2024 1
    Shiloh Anderson 1/2/2024 0.963
    Shiloh Anderson 1/9/2024 0.965
    ThxAlot_1-1737362984793.pngThxAlot_2-1737363094577.png


Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LearnAndPractise(Everyday)


)



For some reason neither of these options worked - the name being returned didn't match the highest average adherence %. I do have a team slicer that is based off a "team" column of this table so that I can filter by team and show the top name for each team. I didn't think that would affect the way the measure was working as it's returning the name of the agent.

shafiz_p
Super User
Super User

Hi @hobosapien  Try this:

Agent MAX Adherence = 
VAR MaxAdherence =
    MAXX(TOPN(1, 'f_Call Metrics', 'f_Call Metrics'[Adherence %]), 'f_Call Metrics'[Agent])
RETURN
    MaxAdherence

 

or 

 

Agent MAX Adherence = 
VAR MaxAdherence =
    TOPN(1, 'f_Call Metrics', 'f_Call Metrics'[Adherence %])
RETURN
    SELECTEDVALUE(MaxAdherence[Agent])

 

or

 

Agent MAX Adherence = 
VAR MaxAdherence =
    TOPN(1, 'f_Call Metrics', 'f_Call Metrics'[Adherence %])
RETURN
    FIRSTNONBLANK(MaxAdherence[Agent],MAX(MaxAdherence[Adherence %]))

 

Hope this helps!!

If this solved your problem, please accept it as a solution and a kudos!!

 

Best Regards,
Shahariar Hafiz

Irwan
Super User
Super User

hello @hobosapien 

 

i got only one name with your DAX (Rafael Beck as the highest value)

Irwan_0-1737330301635.png

 

Thank you.

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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