Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
PaulJ185
New Member

Need Help with Dax Calculations | Count Resolved Date only for MAX Week Numbers

Hi There,

 

I wantto countresoved date only for max week which is 45 in my dataset and row count is 3.

 

PaulJ185_0-1760326074809.png

Expected answer= Resoved Date is 3.

6 REPLIES 6
v-pnaroju-msft
Community Support
Community Support

Hi PaulJ185,

We are following up to see if what we shared solved your issue. If you need more support, please reach out to the Microsoft Fabric community.

Thank you.

v-pnaroju-msft
Community Support
Community Support

Thankyou, @Khashayar, @Shahid12523, @Kedar_Pande, and @danextian for your responses.

Hi PaulJ185,

We appreciate your inquiry through the Microsoft Fabric Community Forum.

We would like to inquire whether have you got the chance to check the solutions provided by @Khashayar, @Shahid12523, @Kedar_Pande and @danextian  to resolve the issue. We hope the information provided helps to clear the query. Should you have any further queries, kindly feel free to contact the Microsoft Fabric community.

Thank you.

danextian
Super User
Super User

Hi @PaulJ185 

 

Assuming week is a measure

Resolved date with max week - Count = 
VAR _SummaryTable =
    SUMMARIZECOLUMNS (
        'Table'[Resolved Date],
        "@week", CALCULATE ( SUM ( 'Table'[Week] ) )
    )
VAR _Max =
    MAXX ( _SummaryTable, [@week] )
RETURN
COUNTROWS ( FILTER ( _SummaryTable, [@week] = _Max ) )

Resolved date with max week = 
VAR _SummaryTable =
    SUMMARIZECOLUMNS (
        'Table'[Resolved Date],
        "@week", CALCULATE ( SUM ( 'Table'[Week] ) )
    )
VAR _Max =
    MAXX ( _SummaryTable, [@week] )
RETURN
MAXX ( FILTER ( _SummaryTable, [@week] = _Max ), [Resolved Date] )

danextian_0-1760358692990.png

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
Kedar_Pande
Super User
Super User

Resolved Count for Max Week =
VAR MaxWeek = CALCULATE(MAX('Table'[Week]), ALL('Table'))
RETURN
CALCULATE(
COUNT('Table'[Resolved Date]),
'Table'[Week] = MaxWeek
)
Shahid12523
Community Champion
Community Champion

DAX Measure: Count for Max Week


ResolvedCount_MaxWeek =
CALCULATE(
COUNTROWS('YourTable'),
FILTER(
'YourTable',
'YourTable'[Week] = CALCULATE(MAX('YourTable'[Week]))
)
)

Shahed Shaikh
Khashayar
Advocate II
Advocate II

You want to count the number of Resolved Dates only for the maximum week (Week = 45) in your dataset.
In Power BI (DAX), you can use this measure:

Resolved Count =

VAR MaxWeek = MAX('YourTable'[Week])

RETURN

COUNTROWS(

    FILTER(

        'YourTable',

        'YourTable'[Week] = MaxWeek

    )

)

Explanation:

  • MAX('YourTable'[Week]) → finds the highest week number (45).
  • FILTER() → keeps only rows where [Week] = 45.
  • COUNTROWS() → counts how many rows meet that condition.

Expected Result:

Resolved Count = 3

If you found this post helpful, please consider accepting it as the solution so that other members can find it more easily.

 

Regards,

Khashayar Yazdani | Microsoft MCT

https://www.linkedin.com/in/khashayary/

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.