Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowJuly 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more
Hello
I have the table:
| Col1 | Col2 | Col3 |
| A | 1 | 01/01/2000 |
| A | 2 | 02/01/2000 |
| A | 1 | 03/01/2000 |
| A | 2 | 04/01/2000 |
| A | 1 | 05/01/2000 |
| A | 1 | 06/01/2000 |
| A | 1 | 07/01/2000 |
etc
After grouping by Col1 (which can be A, B, etc), I want to find the earliest date where Col2=1 after the latest date where Col2=2 for that group A (or B, C etc).
Any idea?
Thanks!
Solved! Go to Solution.
Are you expecting this kind of result?
You can use the measures below:
Earliest Date =
CALCULATE ( MIN ( Data[Col3] ), Data[Col2] = 1, ALLEXCEPT ( Data, Data[Col1] ) )Latest Date =
CALCULATE ( MAX ( Data[Col3] ), Data[Col2] = 2, ALLEXCEPT ( Data, Data[Col1] ) )
Are you expecting this kind of result?
You can use the measures below:
Earliest Date =
CALCULATE ( MIN ( Data[Col3] ), Data[Col2] = 1, ALLEXCEPT ( Data, Data[Col1] ) )Latest Date =
CALCULATE ( MAX ( Data[Col3] ), Data[Col2] = 2, ALLEXCEPT ( Data, Data[Col1] ) )
Hi @Anonymous ,
Can you please elaborate this?
Col2=1 after the latest date where Col2=2
Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.
Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.
| User | Count |
|---|---|
| 22 | |
| 20 | |
| 14 | |
| 13 | |
| 13 |
| User | Count |
|---|---|
| 62 | |
| 40 | |
| 38 | |
| 38 | |
| 38 |