Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
I have a table with multiple entries per user. Each entry represents an event (though that info is not relevant for this question).
user_id | filter |
123 | 30 |
123 | 180 |
355 | 30 |
355 | 60 |
490 | 90 |
The filter column determines if the event was sent X or less days ago. That is:
I use this column as a Slicer to allow the user to select certain periods of time.
I made the following measure to count the number of users that have logged at least one event in the last X days (based on the value that the user sets the slicer to):
events_filtered = DISTINCTCOUNT(my_table[user_id])
Solved! Go to Solution.
Hey @Anonymous ,
you can ignore a slicer with the ALL function. This function you can use as a context modifier in the CALCULATE function.
So the following approach should give you the result you want:
events_filtered =
CALCULATE (
DISTINCTCOUNT ( my_table[user_id] ),
ALL ( filter_Table[filter] )
)
If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
Best regards
Denis
Blog: WhatTheFact.bi
Follow me: twitter.com/DenSelimovic
Hey @Anonymous ,
you can ignore a slicer with the ALL function. This function you can use as a context modifier in the CALCULATE function.
So the following approach should give you the result you want:
events_filtered =
CALCULATE (
DISTINCTCOUNT ( my_table[user_id] ),
ALL ( filter_Table[filter] )
)
If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
Best regards
Denis
Blog: WhatTheFact.bi
Follow me: twitter.com/DenSelimovic
Check out the September 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
112 | |
101 | |
94 | |
38 | |
30 |