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
Be-ro92
Regular Visitor

YTD sum of the average

Hello,

I am trying to create a table where I can show the YTD target for a representative. Since targets cannot be split, I have to show them as duplicates.

Targets are set up as an average per month. And then I would like to sum the average to show the YTD Target with fiscal date starting Oct-2022.

I currently have my DAX as

Total Target = Average('Table1'[Target])
Total Target_2= sumx(values('Table1'[Target]),[Total Target])
Target YTD = CALCULATE([Total Target_2]DATESYTD('Table1'[InvDate] [Date],"09/01"))
 
My Target YTD formula outputs from October to November. It does not include December. What could I be doing wrong?

Rep NameInvoiceSalesInvDateTarget 
Rep11014343771$300Oct-22$1,000 
Rep11322443213$250Oct-22$1,000 
Rep11179412135$250Oct-22$1,000 
Rep11647275203$100Nov-22$500 
Rep11402789444$200Nov-22$500 
Rep11178342331$400Nov-22$500 
Rep11394226361$500Dec-22$700 
Rep11834422269$200Dec-22$700 
Rep11743761730$300Dec-22$700 
      
      
Rep NameInvDateMonthly RevenueMonthly TargetYTD RevenueYTD Target
Rep1Oct-22$800$1,000$1,000$1,000
Rep1Nov-22$700500$1,500$1,500
Rep1Dec-22$1,000$700$2,500$2,200
4 REPLIES 4
Ashish_Mathur
Super User
Super User

Hi,

You may download my PBI file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Could you share the DAX formula? I am unable to open your file.

File is attached.  See signature.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
amitchandak
Super User
Super User

@Be-ro92 , You have use date table joined with date of you table, in visual, slicer, and measure

 

CALCULATE([Total Target_2], DATESYTD('Date'[Date] . [Date],"08/31")) // assuming year start on 09/01

 

Why Time Intelligence Fails - Powerbi 5 Savior Steps for TI :https://youtu.be/OBf0rjpp5Hw
https://amitchandak.medium.com/power-bi-5-key-points-to-make-time-intelligence-successful-bd52912a5b...
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.

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.