Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi,
I know I can concatenate values in PowerQuery, but out of curiosity, I wanted to do in the DAX on the runtime. Seems like I'm unable to do it effectively along with constantly losing the context.
table: DSN_USERS_VW
DSN_ID | USER_GROUP | IDENTIFIER | PRINCIPAL_TYPE |
1 | APP-PBI-DSN-GROUP_A | id-of-the group | group |
1 | marcello.piatti@...com | user | |
1 | anna.marina@...com | user |
I'm trying to build a link to the portal.azure.com to which see the members of the group if the PRINCIPAL_TYPE is group, if it's user, return blank.
_render_asLink = CALCULATE(
IF(
MAX(DSN_USERS_VW[PRINCIPAL_TYPE]) = "Group", CONCATENATE("htt..portal.azure.com/../groupId/", MAX(DSN_USERS_VW[IDENTIFIER])), BLANK()
),
KEEPFILTERS(DSN_USERS_VW)
)
I seriously don't like having to use the aggregation but seem like I have it. Is this the best way to do it?
When I say it ignores the context, I have another table DSN_VW and the table visual using the data. normally, if I don't have the _render_asLink measunre in the other visual, the DSN_VW filters DSN_USERS_VW nicely, however, with the measure in the latter it always returns all of them. I think I might be having the context wrong there...
Thanks for all your help!
try this:
_render_asLink = CALCULATE(
IF(
MAX(DSN_USERS_VW[PRINCIPAL_TYPE]) = "Group", "htt..portal.azure.com/../groupId/"& MAX(DSN_USERS_VW[IDENTIFIER]), BLANK()
),
KEEPFILTERS(DSN_USERS_VW)
)
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
14 | |
9 | |
7 | |
7 | |
6 |
User | Count |
---|---|
20 | |
11 | |
10 | |
9 | |
7 |