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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
NipawanV
Helper I
Helper I

YTD doesn't return the right value

I created YTD formula but it doesn't return the expected value YTD value. Do you have any clue?

Customer Price YTD =
CALCULATE(
    [Customer Price],
    DATESYTD(DimDate[Date])
)
 
NipawanV_0-1701326511162.png


Current Price is the mesure field: 

CustomerPrice =
VAR SalesAmount = SUM(F_PricingDashboard[Sales Amount Domestic])
VAR SalesQTY = SUM(F_PricingDashboard[Sales Quantity (Sales Time)])
RETURN
DIVIDE(SalesAmount,SalesQTY,0)
 
I have Date table well set start from 01/01/2020 etc.

I test with the other measure field that link with the other date table. Formula look ok.

NipawanV_0-1701327046044.png

 

 
2 REPLIES 2
FreemanZ
Super User
Super User

hi @NipawanV ,

 

Everything seems OK. what are you expected price YTD on different months? 

Hello, 

Thanks for the quick response. 

I just want to cross-check if the result given in the first table is correct calculation of YTD .  As to my understanding the YTD suppose to be like in this figure below and the example from previous table on my second picture that show YTD of the Est. Reveue YTD as it's suppose to be which is quite correct in my opinion. 

NipawanV_0-1701334734204.png


So if it's correct.  I want to know how does PBI calculate Customer Price YTD on the above table to get such figures. 

  

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.