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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Paulyeo11
Impactful Individual
Impactful Individual

My Supplier YTD Amount return null ?

Hi All

 

Below is my YTD expression :-
_YTD AMT = CALCULATE(SUM('SUPPLIER'[AMT_SGD]),
FILTER('Date',
'Date'[Year] = CALCULATE(max('Date'[Year]),
FILTER(ALL('SUPPLIER'),
'SUPPLIER'[Name]=MAX('SUPPLIER'[SUPPLIER NAME_])))))
 

When i select year=2020 , i hope that _YTD_AMT display 2020 sales amount , the expression return null.

Paulyeo11_0-1610015169781.png

https://www.dropbox.com/s/jid7buovc5m1p1m/PBT_SAMPLE%20100%20ROW%20JAN%202021%20V006.pbix?dl=0

Aboce is my PBI file.

 

Paul

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Paulyeo11 , Why are not using datesytd

_YTD AMT = CALCULATE(SUM('SUPPLIER'[AMT_SGD]),
  DATESYTD('Date'[Date]))

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Paulyeo11 , Why are not using datesytd

_YTD AMT = CALCULATE(SUM('SUPPLIER'[AMT_SGD]),
  DATESYTD('Date'[Date]))

Hi Amit

Thank you for your help

Paul

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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