Forum Discussion
pdbenbow
Resolver II
7 years agoConcatenating data within RELATEDTABLE output
My report has a list of email addresses, and the request from the users is to have a "mailto" hyperlink they can click to send an email to all addresses. The list needs to be dynamic based on slicer...
- 7 years ago
I was able to get what I needed by converting the calculated column into a measure.
DAX:
Email All = "mailto: " & CONCATENATEX(VALUES(ENVH[Email]),ENVH[Email],"; ")
Anonymous
7 years agoNot applicable
Can you show the model, please? RELATEDTABLE goes from the one side of the relation to the many side. I'd like to know what you store in your tables and how they're linked and by which fields you slice. Without this knowledge I don't think anyone could give you a correct answer...
Best
D.
Best
D.
pdbenbow
Resolver II
7 years agoThe data model is a single table with no relationships. That's why I don't think RELATEDTABLE is what I should be using. There must be another way to concatenate the values after they've been sliced.
- Anonymous7 years agoNot applicable
[Email All] = var __concatenatedEmails = CONCATENATEX( DISTINCT( ENVH[Email] ), ENVH[Email], "; " ) var __mailtoString = "mailto:" & __concatenatedEmails return __mailtoString
- pdbenbow7 years ago
Resolver II
Nope, doesn't work. That gives me the exact same result as my original formula:
Original formula:
Email All = "mailto:" & CONCATENATEX( ENVH, ENVH[Email], "; ")
Here is the output when not sliced:
Here is the output when sliced:
The slicer is having no effect. When I toggle that slicer, there should only be three email addresses listed.