March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
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
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
129 | |
90 | |
75 | |
58 | |
53 |
User | Count |
---|---|
200 | |
104 | |
101 | |
67 | |
55 |