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
I am trying to determine the first user to touch an account and to exclude any automate touches. For example, below is my data. For account 1, the first user should be Bob and for account 2, the first user should be Jim. I am dealing with millions of rows so anyway to do this in a measure? Thanks!
| Account | User | Activity | Index |
| 1 | Ann | Sell | 1 |
| 1 | Bob | Buy | 2 |
| 1 | Automate | Sell | 3 |
| 2 | Cally | Sell | 4 |
| 2 | Sam | Buy | 5 |
| 2 | Jim | Sell | 6 |
Solved! Go to Solution.
@PowerBI123456 , Try a new measure like
measure = calculate(sum(Table[Index]), filter(Table,Table[Index] = calculate(max(Table[Index]), allexpcept(Table,table[Account]), table[Activity] <> "Automate")))
@amitchandak Looking at the index. First user who has the greatest index per account and that user cannot be "automate". Does that help?
@PowerBI123456 , Try a new measure like
measure = calculate(sum(Table[Index]), filter(Table,Table[Index] = calculate(max(Table[Index]), allexpcept(Table,table[Account]), table[Activity] <> "Automate")))
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 41 | |
| 38 | |
| 33 | |
| 29 | |
| 24 |
| User | Count |
|---|---|
| 126 | |
| 115 | |
| 85 | |
| 69 | |
| 69 |