While standard DAX time functions (TOTALYTD, SAMEPERIODLASTYEAR) work seamlessly for standard Gregorian calendar years (January to December), large enterprises—especially in retail, hospitality, and manufacturing—operate on custom non-standard fiscal calendars:
4-4-5, 4-5-4, or 5-4-4 Retail Calendars (where every quarter consists of two 4-week months and one 5-week month so that quarters always have exactly 13 weeks).
Custom Rolling Windows (Trailing 12 Months - T12M, 30-day moving averages).
Standard DAX time intelligence functions FAIL COMPLETELY on 4-4-5 retail calendars! Advanced BI architects author custom time intelligence patterns using pure filter manipulation.
1. Rolling Moving Averages (Trailing 30 Days / 90 Days)
A moving average smooths out daily sales volatility to reveal true underlying demand trends:
In a 4-4-5 calendar, months do not align with standard date ranges. The Date table contains custom attributes: FiscalYear, FiscalWeekNumber, FiscalPeriod.
1-- Custom Fiscal YTD on 4-4-5 Calendar (Bypasses TOTALYTD!)
Test your understanding of this lesson with 5 questions. Each question has one correct answer.
12-Month Data Analysis Mastery Program
Master Full-Stack Data Analytics (Excel, SQL, Python, Power BI & Tableau)
Combine 15 complete courses, 150 chapters, 541 topics, live SQL/Power BI/Tableau dashboards, and Scikit-Learn capstones at MSK Institute Shikohabad or Live Online.