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
mrslyfox
Helper II
Helper II

TOTALMTD empty days

Hello,

 

Have a folowing formula

MTD Sales:=TOTALMTD(SUM(F_Delivery_Note[DELNL_TotalGrossSqm]),D_Date[LINK_Date])

 

Which gives me almost expected results.

Trouble only with last marked by red days. Result for those days should blank.

TOTALMTD.png

1 ACCEPTED SOLUTION

Hey

 

your formula should look like this

MTD Sales:=IF(
 NOT(
  ISBLANK(
   SUM(F_Delivery_Note[DELNL_TotalGrossSqm])))
   ,TOTALMTD(SUM(F_Delivery_Note[DELNL_TotalGrossSqm]),D_Date[LINK_Date])
   ,BLANK()
  )

 

 



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

3 REPLIES 3
TomMartens
Super User
Super User

A quick solution would be to put your calculation into an if statement, that checks if your measure is not null like this

 

IF(NOT(ISBLANK(sum of your measure)), your calculation, BLANK())

 

You have to consider that this formula also surpresses the calculation for days where there is no data, for a business reason.



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Hello @TomMartens

 

Result of

MTD Sales:=IF(NOT(ISBLANK(TOTALMTD(SUM(F_Delivery_Note[DELNL_TotalGrossSqm]),D_Date[LINK_Date]))),TOTALMTD(SUM(F_Delivery_Note[DELNL_TotalGrossSqm]),D_Date[LINK_Date]),BLANK())

 

returned the same result as it was from the beginning.

Hey

 

your formula should look like this

MTD Sales:=IF(
 NOT(
  ISBLANK(
   SUM(F_Delivery_Note[DELNL_TotalGrossSqm])))
   ,TOTALMTD(SUM(F_Delivery_Note[DELNL_TotalGrossSqm]),D_Date[LINK_Date])
   ,BLANK()
  )

 

 



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

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.