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! It's time to submit your entry. Live now!
Hello All,
I am looking to get a count of orders by account. I have an example of the columns i have below.
More specificly im looking for a formula that would look at each account and give me a count of orders after the order a specific event.
| Account | OrderKey | Event ID | Event Date | Order Date |
| abc1 | 55 | 111 | 1/1/2021 | 1/1/2021 |
| abc2 | 56 | 112 | 4/1/2021 | 3/25/2021 |
| abc3 | 57 | 112 | 4/1/2021 | 2/10/2021 |
| abc1 | 58 | 112 | 4/1/2021 | 1/6/2021 |
| abc2 | 59 | 111 | 1/1/2021 | 10/10/2021 |
| abc3 | 60 | 113 | 10/1/2021 | 2/10/2021 |
| abc1 | 61 | 113 | 10/1/2021 | 1/25/2021 |
| abc1 | 61 | 114 | 11/1/2021 | 1/25/2021 |
So if i use a event id slicer and select Event ID "111" the account abc1 would return the following
| Slicer : Event ID 111 | |
| Account | Count of orders |
| abc1 | 3 |
| abc2 | 0 |
Ive been racking my brain for a formula for quite a while and am just looking for a bit of guidence,
Thank you for any help.
Adam
Solved! Go to Solution.
| Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension! |
DAX is simple, but NOT EASY! |
| Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension! |
DAX is simple, but NOT EASY! |
Thank you very much for your help this worked for me!
No they are not.
Of course, so abc 2 only purchased EventID 111 and did not purchase any other Event after that.
The Power BI Data Visualization World Championships is back! It's time to submit your entry.
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 60 | |
| 49 | |
| 30 | |
| 25 | |
| 23 |
| User | Count |
|---|---|
| 131 | |
| 103 | |
| 58 | |
| 39 | |
| 31 |