Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
https://www.sqlbi.com/articles/the-definitive-guide-to-allselected/
I can see that iteration on allselected creates a shadow context
I use ALLSELECTED inside SUMX
so how can I handle my problem
I need the unique count of person whose tickets are open
which means I need to consider only 1 ticket for person when I have 2 open tickets
ticket which needs to be considered as latest open ticket (max of open_dt)
this is my dax for finding the unique count
which results in total in table as correct but the values are still the same as my open ticket count measure
attaching my example file
https://drive.google.com/file/d/1G_sfyGqbAyCbxA359lShcC6z06zDWYIA/view?usp=share_link
Proud to be a Super User!
sure, you have incorporated the logic of open inside the measure but my logic has mutiple conditions for open & my table has 10 millions rows
I just added a simple logic for the understanding
I need the same results using open ticket count measure
thank you
Than change it like this:
Proud to be a Super User!
ss
placed the measure but it is returning the same value as open_dt
You mentionied this, what you want zu see (yellow):
I send you this: (measure definition in my previous post)
You build this:
Delete the columns open_dt and close_dt in your matrix. 🙂
Than you get the yellow marked rows. If you want something else please make a little example in excel what do you want to see excatly.
Proud to be a Super User!
You can not but open_dt and close_dt in this matrix. look to my matrix.
Proud to be a Super User!
can you share the pbix file
I replaced the same measure as you sent but got the max date as open_dt
Make a matrix in excel and show us what you want to see 1:1 🙂
Proud to be a Super User!
Your open_dt and close_dt columns are the reason for the current matrix. can you please share exactly how the matrix should look like?
Proud to be a Super User!
out of these 9 rows I only need to see the highlighted 2 rows
i.e. distinct count of a person who has latest open ticket
thanks for helpin me out @andhiii079845
I don't know how it is affecting but
I have attached the link for the sample file
I need to show the table for distinct count of person whose tickets are open
i.e. only 1 row should be considered for a person (if 2 open tickets are there for same person then max open_dt row should be considered)
I should show only the highlighted rows & my count should be 2
https://drive.google.com/file/d/1G_sfyGqbAyCbxA359lShcC6z06zDWYIA/view?usp=share_link
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 41 | |
| 38 | |
| 36 | |
| 30 | |
| 28 |
| User | Count |
|---|---|
| 128 | |
| 88 | |
| 79 | |
| 67 | |
| 62 |