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
sohananahid
Post Partisan
Post Partisan

How to show multiple values [with comma separated] for a field in Tooltip

Hi all: Good Day! I have a Map showing different events happening on different locations. There are instances that one location_id may have multiple events: event1, event2,…with start date1, end date1, ..and start date2, end date2, .. I am trying to show these info in Tooltip as I hover over a location bubble. Most of the time I have found single value for these fields and sometimes a max of  2/3  values. The tooltip shows aggregated -min, max, earliest, latest,…

I am trying to find a way, e.g. write a measure to use for these fields in the tooltip so that

event field will show event1, event2,..

start date will show: start date1, start date2,..

end date will show: end date1, end date2, ..

Could you suggest how to write it? Many thanks in advance. 🙂

1 ACCEPTED SOLUTION
V-lianl-msft
Community Support
Community Support

Hi @sohananahid ,

 

Try this:

Measure 2 =
CONCATENATEX (
    FILTER (
        'Table (3)',
        COUNTROWS (
            FILTER ( 'Table (3)', EARLIER ( 'Table (3)'[BOM] ) = 'Table (3)'[BOM] )
        )
    ),
    'Table (3)'[Raw material2],
    ","
)

Refer to this sample

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
V-lianl-msft
Community Support
Community Support

Hi @sohananahid ,

 

Try this:

Measure 2 =
CONCATENATEX (
    FILTER (
        'Table (3)',
        COUNTROWS (
            FILTER ( 'Table (3)', EARLIER ( 'Table (3)'[BOM] ) = 'Table (3)'[BOM] )
        )
    ),
    'Table (3)'[Raw material2],
    ","
)

Refer to this sample

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi 

 

Is there any way to get distinct values in concatenatex using DAX?   

 

Thanks!

Greg_Deckler
Super User
Super User

@sohananahid - You can use CONCATENATEX. To be more specific, would need sample data. Please first check if your issue is a common issue listed here: https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882

Also, please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

The most important parts are:
1. Sample data as text, use the table tool in the editing bar
2. Expected output from sample data
3. Explanation in words of how to get from 1. to 2.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...
richbenmintz
Solution Sage
Solution Sage

Hi @sohananahid,

 

Please try a formula like 

Events = CONCATENATEX('Table', [Event], ",")

 

results look like this

richbenmintz_0-1596728635264.png

 

Hope this Helps,

Richard


Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!



I hope this helps,
Richard

Did I answer your question? Mark my post as a solution! Kudos Appreciated!

Proud to be a Super User!


amitchandak
Super User
Super User

@sohananahid , Can you share sample data and sample output in table format?

 

You can check if concatenatex van help

https://docs.microsoft.com/en-us/dax/concatenatex-function-dax

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.