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.
Hi,
There are two tables (or more) in which I have 'Users' column for each dimension, and I am looking for a single measure which would give me the count of users, when I select the filters.
Consider the below scenario where I have multiple dimesions (like City, Country, Laptop Name etc)
My client wants the dimensions as filters on the dashboard, so that he can slice and dice the count of users, but only wants a single card where he can see the count.
For eg: If the client selects say UK from the "Region" - it should display count of users for UK, If the selection is Dell from "Laptop Name" then it should show the count of users for that correspondingly.
Understand there is no common column between both the tables. Just curious if this can be pulled off.
Thanks for your help in advance.
Regards,
Shashank
Solved! Go to Solution.
You can do something like this:
MEASURE =
VAR1 = Sum(Table1[Users])
VAR2 = Sum(Table2[Users])
RETURN
SWITCH(
TRUE;
ISFILTERED(Table1); VAR1;
ISFILTERED(Table2); VAR2
)
This should work if there aren't other complications in the data
Create a common user table
User =distinct(union(all(table1[user]),all(table2[user])))
Join it both the tables. Or you can count distinct user from it
You can do something like this:
MEASURE =
VAR1 = Sum(Table1[Users])
VAR2 = Sum(Table2[Users])
RETURN
SWITCH(
TRUE;
ISFILTERED(Table1); VAR1;
ISFILTERED(Table2); VAR2
)
This should work if there aren't other complications in the data
It Workeed. Thank you so much @Anonymous
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
95 | |
76 | |
65 | |
51 |
User | Count |
---|---|
146 | |
109 | |
106 | |
88 | |
61 |