Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
I have a table with all the social media posts made by my company for the last two years. Wanting to get a new measurement that shows the number made YTD and then another that shows the amount for same period last year. I can get the current year, but previous year won't work.
Hello @Anonymous,
Can you please try this:
1. Current Year YTD Posts Calculation
YTD Posts = CALCULATE(
DISTINCTCOUNT('Social Performance'[Post ID]),
DATESYTD('Social Performance'[Date], "12/31")
)
2. Previous Year YTD Posts Calculation
LY Posts = CALCULATE(
DISTINCTCOUNT('Social Performance'[Post ID]),
SAMEPERIODLASTYEAR(DATESYTD('Date'[Date], "12/31"))
)
The LY Posts is showing CUMULATIVE by week, when I want it to show by week. The YTD Posts works correctly.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.