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!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi ,
i have the below Table
| AccID | Category | AccStatus | Date |
| ab133 | xyz | Open | 1/1/2020 |
| ab133 | abc | Open | 1/1/2020 |
| ab133 | cde | Open | 1/1/2020 |
| ab133 | efz | Closed | 1/1/2020 |
| cd354 | xyz | Open | 1/6/2020 |
| cd354 | abc | Closed | 1/2/2020 |
| dc566 | cde | Open | 1/3/2020 |
| gf345 | xyz | Open | 1/4/2020 |
i want to calculate "AccID" who have the "AccStatus" as "Open" for each "Category" with Latest Date.
it has to count the Highlighted Rows
| AccID | Category | AccStatus | Date |
| ab133 | xyz | Open | 1/1/2020 |
| ab133 | abc | Open | 1/1/2020 |
| ab133 | cde | Open | 1/1/2020 |
| ab133 | xyz | Closed | 1/2/2020 |
| ab133 | efz | Closed | 1/1/2020 |
| cd354 | xyz | Open | 1/2/2020 |
| cd354 | abc | Closed | 1/6/2020 |
| dc566 | cde | Open | 1/3/2020 |
| gf345 | xyz | Open | 1/4/2020 |
| gf345 | xyz | Closed | 1/1/2020 |
if this measure >0 , the you need to color the column as green using conditional formatting
new Count =
VAR __id = MAX ('Table'[AccID] )
VAR __date = CALCULATE ( MAX('Table'[Date] ), ALLSELECTED ('Table' ), 'Table'[AccID] = __id , 'Table'[AccStatus] = "Open")
CALCULATE ( Count ('Table'[Date] ), VALUES ('Table'[AccID] ),'Table'[AccID] = __id,'Table'[Date] = __date , 'Table'[AccStatus] = "Open" )+0
max open date
new Date =
VAR __id = MAX ('Table'[AccID] )
VAR __date = CALCULATE ( MAX('Table'[Date] ), ALLSELECTED ('Table' ), 'Table'[AccID] = __id , 'Table'[AccStatus] = "Open")
CALCULATE ( Max ('Table'[Date] ), VALUES ('Table'[AccID] ),'Table'[AccID] = __id,'Table'[Date] = __date , 'Table'[AccStatus] = "Open" )
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 9 | |
| 9 | |
| 8 | |
| 6 | |
| 6 |
| User | Count |
|---|---|
| 20 | |
| 18 | |
| 16 | |
| 14 | |
| 14 |