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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
priya_rajendran
Frequent Visitor

Is it possible to get the Max value in the grand total alone

Hi, 

Is it possible to get the Max value / the latest value of the measure in the grand total alone ?

My measure:

Opening_HC =
var start_ = STARTOFMONTH(calendar_dim[cal_dt])
var end_ = ENDOFMONTH(calendar_dim[cal_dt])
var thisday = TODAY()

var opening = CALCULATE(distinctCOUNT('active+attrition'[Associate ID]),ALLEXCEPT('active+attrition','CC Details'[Tech Org 1],'CC Details'[IDC CC]),'active+attrition'[Date of Joining]<start_,'active+attrition'[Last Working Date]>= start_)

RETURN
IF(and(start_ <= DATE(YEAR(TODAY()), MONTH(TODAY()), 1),[Closing_HC]>0),opening)
 

hc_snap4.PNG

 

 

 

1 ACCEPTED SOLUTION
v-kkf-msft
Community Support
Community Support

Hi @priya_rajendran ,

 

Has your problem been solved? If it is solved, please mark a reply which is helpful to you.

 

If the problem is still not resolved, please try the measure.

 

Total = 
IF (
    ISFILTERED ( calendar_dim[Month] ),
    [Opening_HC],
    MAXX ( VALUES ( calendar_dim[Month] ), [Opening_HC] )
)

vkkfmsft_0-1657175914831.png

 

Best Regards,
Winniz


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-kkf-msft
Community Support
Community Support

Hi @priya_rajendran ,

 

Has your problem been solved? If it is solved, please mark a reply which is helpful to you.

 

If the problem is still not resolved, please try the measure.

 

Total = 
IF (
    ISFILTERED ( calendar_dim[Month] ),
    [Opening_HC],
    MAXX ( VALUES ( calendar_dim[Month] ), [Opening_HC] )
)

vkkfmsft_0-1657175914831.png

 

Best Regards,
Winniz


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks much! This worked 🙂

amitchandak
Super User
Super User

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.