<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Need Urgent help! on DAX: Adjustment Needed for Measure to Align with 4-4-5 Calendar in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4666848#M178754</link>
    <description>&lt;P class=""&gt;&lt;STRONG&gt;Hi All,&lt;/STRONG&gt;&lt;/P&gt;&lt;P class=""&gt;I actually found a solution for this but forgot to share it earlier. The measure below works perfectly for my requirement.&lt;/P&gt;&lt;P class=""&gt;Essentially, we needed to track units for the &lt;STRONG&gt;last 7 years&lt;/STRONG&gt;, comparing data from the current period going back exactly 84 months. Initially, the logic worked fine for past years, but now that we’re in &lt;STRONG&gt;2025&lt;/STRONG&gt;, the comparison was incorrectly using the &lt;STRONG&gt;entire calendar year (Jan–Dec)&lt;/STRONG&gt; of 2025 against the last six full years — which doesn't align with the requirement.&lt;/P&gt;&lt;P class=""&gt;However, with the new measure, it now calculates correctly — taking &lt;STRONG&gt;date-to-date logic&lt;/STRONG&gt; into account. For example, as of &lt;STRONG&gt;24th April 2025&lt;/STRONG&gt;, it pulls data going back exactly to &lt;STRONG&gt;24th May 2019&lt;/STRONG&gt;, covering the &lt;STRONG&gt;last 84 months&lt;/STRONG&gt; precisely which is 7 years.&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Cumulative Units Last &lt;/SPAN&gt;&lt;SPAN&gt;7&lt;/SPAN&gt;&lt;SPAN&gt; Years NEW =&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;TODAY&lt;/SPAN&gt;&lt;SPAN&gt;() &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;-- Get today's actual date&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;CurrentYear&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;YEAR&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt;) &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;-- Extract the current year&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;[Full_Date]&lt;/SPAN&gt;&lt;SPAN&gt;) &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;-- Get the max date in context&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;-- Adjust the max date only if the report is showing the current year&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;AdjustedMaxDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;IF&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt; &amp;gt; &lt;/SPAN&gt;&lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp;&amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;YEAR&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt;) = &lt;/SPAN&gt;&lt;SPAN&gt;CurrentYear&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;-- Calculate the start date (7 years before the adjusted max date)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;StartDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;EDATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;AdjustedMaxDate&lt;/SPAN&gt;&lt;SPAN&gt;, -&lt;/SPAN&gt;&lt;SPAN&gt;84&lt;/SPAN&gt;&lt;SPAN&gt;) &amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;RETURN&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;[Units]&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;ALL&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;[Full_Date]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;gt;= &lt;/SPAN&gt;&lt;SPAN&gt;StartDate&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp;&amp;amp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;[Full_Date]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt;= &lt;/SPAN&gt;&lt;SPAN&gt;AdjustedMaxDate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Thu, 24 Apr 2025 13:16:44 GMT</pubDate>
    <dc:creator>Srinivas904</dc:creator>
    <dc:date>2025-04-24T13:16:44Z</dc:date>
    <item>
      <title>Need Urgent help! on DAX: Adjustment Needed for Measure to Align with 4-4-5 Calendar</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4592841#M175885</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;The measure is working correctly for prior years, but for the current year, it is incorrectly comparing the full year to -6 years. Instead, it should calculate exactly 7 years back.&lt;/P&gt;&lt;P&gt;For example, since we are in March 2025, the calculation should consider data from March 2018 to March 2025. However, it is currently calculating from &lt;STRONG&gt;03/03/2025 to 03/03/2018&lt;/STRONG&gt;, which is exactly 7 years. While this isn’t necessarily wrong, our &lt;STRONG&gt;custom 4-4-5 calendar&lt;/STRONG&gt; defines March 2018 as starting from &lt;STRONG&gt;26/02/2018&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;The required adjustment is to ensure that the measure correctly calculates from &lt;STRONG&gt;the full March 2025 period back to the full March 2018 period&lt;/STRONG&gt;, based on our 4-4-5 calendar structure.&lt;/P&gt;&lt;P&gt;Can someone help adjust the measure to align with this?&lt;/P&gt;&lt;P&gt;Just to confirm, we use the &lt;STRONG&gt;4-4-5 calendar&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;If you look at the data in the screenshot below, the value for 2025 should be &lt;STRONG&gt;63,234&lt;/STRONG&gt;, which is correctly selected from March 2018. However, in the screenshot above, the value for 2025 is incorrect.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;If you look at the screenshot below, I have selected only &lt;STRONG&gt;1803 (March 2018)&lt;/STRONG&gt; while excluding data up to &lt;STRONG&gt;05/03/2025&lt;/STRONG&gt;, where the value is &lt;STRONG&gt;845&lt;/STRONG&gt;. However, when I unselect the date filter and check the screenshot below, the value is &lt;STRONG&gt;965&lt;/STRONG&gt;, which represents the entire month.&lt;/P&gt;&lt;P&gt;If we add &lt;STRONG&gt;63,204 + 120&lt;/STRONG&gt;, we get &lt;STRONG&gt;63,324&lt;/STRONG&gt;, which matches the value shown in the screenshot above.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;this is the measure i am using the bar graph&lt;/P&gt;&lt;P&gt;Cumulative Units Last 7 Years =&lt;BR /&gt;VAR TodayDate = TODAY() -- Get today's actual date&lt;BR /&gt;VAR CurrentYear = YEAR(TodayDate) -- Extract the current year&lt;BR /&gt;VAR CurrentMaxDate = MAX(DIM_TIME[Full_Date]) -- Get the max date in context&lt;/P&gt;&lt;P&gt;-- Adjust the max date only if the report is showing the current year&lt;BR /&gt;VAR AdjustedMaxDate = IF(CurrentMaxDate &amp;gt; TodayDate &amp;amp;&amp;amp; YEAR(CurrentMaxDate) = CurrentYear, TodayDate, CurrentMaxDate)&lt;/P&gt;&lt;P&gt;-- Calculate the start date (7 years before the adjusted max date)&lt;BR /&gt;VAR StartDate = EDATE(AdjustedMaxDate, -84)&lt;/P&gt;&lt;P&gt;RETURN&lt;BR /&gt;CALCULATE(&lt;BR /&gt;[Units],&lt;BR /&gt;FILTER(&lt;BR /&gt;ALL(DIM_TIME),&lt;BR /&gt;DIM_TIME[Full_Date] &amp;gt;= StartDate &amp;amp;&amp;amp;&lt;BR /&gt;DIM_TIME[Full_Date] &amp;lt;= AdjustedMaxDate&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Srinivas&lt;/P&gt;</description>
      <pubDate>Mon, 03 Mar 2025 11:47:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4592841#M175885</guid>
      <dc:creator>Srinivas904</dc:creator>
      <dc:date>2025-03-03T11:47:22Z</dc:date>
    </item>
    <item>
      <title>Re: Need Urgent help! on DAX: Adjustment Needed for Measure to Align with 4-4-5 Calendar</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4592845#M175886</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="643535" data-lia-user-login="Srinivas904" class="lia-mention lia-mention-user"&gt;Srinivas904&lt;/a&gt;&amp;nbsp;, Try using&lt;/P&gt;
&lt;P&gt;DAX&lt;BR /&gt;Cumulative Units Last 7 Years =&lt;BR /&gt;VAR TodayDate = TODAY() -- Get today's actual date&lt;BR /&gt;VAR CurrentYear = YEAR(TodayDate) -- Extract the current year&lt;BR /&gt;VAR CurrentMaxDate = MAX(DIM_TIME[Full_Date]) -- Get the max date in context&lt;/P&gt;
&lt;P&gt;-- Adjust the max date only if the report is showing the current year&lt;BR /&gt;VAR AdjustedMaxDate = IF(CurrentMaxDate &amp;gt; TodayDate &amp;amp;&amp;amp; YEAR(CurrentMaxDate) = CurrentYear, TodayDate, CurrentMaxDate)&lt;/P&gt;
&lt;P&gt;-- Calculate the start date (7 years before the adjusted max date)&lt;BR /&gt;VAR StartDate = EDATE(AdjustedMaxDate, -84)&lt;/P&gt;
&lt;P&gt;-- Adjust the start date to align with the 4-4-5 calendar&lt;BR /&gt;VAR AdjustedStartDate = &lt;BR /&gt;CALCULATE(&lt;BR /&gt;MIN(DIM_TIME[Full_Date]),&lt;BR /&gt;FILTER(&lt;BR /&gt;ALL(DIM_TIME),&lt;BR /&gt;DIM_TIME[Full_Date] &amp;gt;= StartDate &amp;amp;&amp;amp;&lt;BR /&gt;DIM_TIME[Full_Date] &amp;lt;= EOMONTH(StartDate, 0)&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;RETURN&lt;BR /&gt;CALCULATE(&lt;BR /&gt;[Units],&lt;BR /&gt;FILTER(&lt;BR /&gt;ALL(DIM_TIME),&lt;BR /&gt;DIM_TIME[Full_Date] &amp;gt;= AdjustedStartDate &amp;amp;&amp;amp;&lt;BR /&gt;DIM_TIME[Full_Date] &amp;lt;= AdjustedMaxDate&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;</description>
      <pubDate>Mon, 03 Mar 2025 11:51:27 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4592845#M175886</guid>
      <dc:creator>bhanu_gautam</dc:creator>
      <dc:date>2025-03-03T11:51:27Z</dc:date>
    </item>
    <item>
      <title>Re: Need Urgent help! on DAX: Adjustment Needed for Measure to Align with 4-4-5 Calendar</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4592889#M175889</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="625922" data-lia-user-login="bhanu_gautam" class="lia-mention lia-mention-user"&gt;bhanu_gautam&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;I tried it but the values didn't changed still same values. can you please help me on this ?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Srinivas&lt;/P&gt;</description>
      <pubDate>Mon, 03 Mar 2025 12:16:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4592889#M175889</guid>
      <dc:creator>Srinivas904</dc:creator>
      <dc:date>2025-03-03T12:16:39Z</dc:date>
    </item>
    <item>
      <title>Re: Need Urgent help! on DAX: Adjustment Needed for Measure to Align with 4-4-5 Calendar</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4666535#M178742</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="643535" data-lia-user-login="Srinivas904" class="lia-mention lia-mention-user"&gt;Srinivas904&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Thank you for reaching out to Microsoft Fabric Community.&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thank you&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="625922" data-lia-user-login="bhanu_gautam" class="lia-mention lia-mention-user"&gt;bhanu_gautam&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;for the prompt response.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;The problem is that the current DAX measure doesn't fully account for the 4-4-5 calendar alignment, especially for the start and end of a given "month" based on that custom calendar.&lt;/P&gt;
&lt;P&gt;The current logic just offsets by -84 months (i.e. 7 years back), but doesn’t align to the start of the custom period (like "March 2018" as per your 4-4-5 calendar). So, you end up misaligned totals when slicing across months.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Here are some steps to fix it:&lt;/STRONG&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Use the Period ID or Fiscal Year-Month from your 4-4-5 calendar (DIM_TIME) to determine the current and 7-year-prior period.&lt;/LI&gt;
&lt;LI&gt;Align calculations to full periods using DIM_TIME[Period_ID] or whatever field denotes fiscal periods (like 1803, 2503, etc.).&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&lt;STRONG&gt;Try using the below updated DAX Measure:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Cumulative Units Last 7 Fiscal Years = &lt;BR /&gt;VAR MaxDate = MAX(DIM_TIME[Full_Date])&lt;BR /&gt;VAR MaxPeriod = MAX(DIM_TIME[Period_ID]) -- assuming you have a custom field like 2503 for Mar 2025&lt;BR /&gt;VAR StartPeriod = MaxPeriod - 700 -- subtracting 7 years (you may need to adjust this logic based on how your Period_IDs are structured)&lt;/P&gt;
&lt;P&gt;RETURN&lt;BR /&gt;CALCULATE(&lt;BR /&gt;[Units],&lt;BR /&gt;FILTER(&lt;BR /&gt;ALL(DIM_TIME),&lt;BR /&gt;DIM_TIME[Period_ID] &amp;gt;= StartPeriod &amp;amp;&amp;amp;&lt;BR /&gt;DIM_TIME[Period_ID] &amp;lt;= MaxPeriod&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;DIM_TIME[Period_ID] is something like 1803, 1903, etc., that identifies fiscal month-year. If it’s text or has a different format, we can adapt the subtraction logic using ranking or indexing.&lt;/P&gt;
&lt;P&gt;If you don’t have numeric Period_IDs:&lt;BR /&gt;You can create a rank column in your DIM_TIME table using Power BI modeling:&lt;/P&gt;
&lt;P&gt;PeriodRank = RANKX(ALL(DIM_TIME), DIM_TIME[Full_Date], , ASC, DENSE)&lt;BR /&gt;Then modify the measure like this:&lt;/P&gt;
&lt;P&gt;Cumulative Units Last 7 Fiscal Years = &lt;BR /&gt;VAR MaxRank = MAX(DIM_TIME[PeriodRank])&lt;BR /&gt;VAR StartRank = MaxRank - 84 -- 7 years back (12 months * 7 years)&lt;/P&gt;
&lt;P&gt;RETURN&lt;BR /&gt;CALCULATE(&lt;BR /&gt;[Units],&lt;BR /&gt;FILTER(&lt;BR /&gt;ALL(DIM_TIME),&lt;BR /&gt;DIM_TIME[PeriodRank] &amp;gt;= StartRank &amp;amp;&amp;amp;&lt;BR /&gt;DIM_TIME[PeriodRank] &amp;lt;= MaxRank&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;Make sure your DIM_TIME includes columns like:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;FiscalYearMonth (e.g. "2025-03")&lt;/LI&gt;
&lt;LI&gt;Period_ID (e.g. 2503)&lt;/LI&gt;
&lt;LI&gt;PeriodRank&lt;/LI&gt;
&lt;LI&gt;Validate that your time slicer is using those fiscal fields (not default Gregorian ones).&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;Cross-check with business definitions: ensure “March 2018” starts 26/02/2018 and ends accordingly.&lt;/P&gt;
&lt;P&gt;If this post&amp;nbsp;helps, then please consider&amp;nbsp;Accepting as solution&amp;nbsp;to help the other members find it more quickly,&amp;nbsp;don't forget to give a&amp;nbsp;"Kudos"&amp;nbsp;– I’d truly appreciate it!&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;SPAN data-teams="true"&gt;&amp;nbsp;Thank you.&lt;/SPAN&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Apr 2025 11:24:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4666535#M178742</guid>
      <dc:creator>v-venuppu</dc:creator>
      <dc:date>2025-04-24T11:24:22Z</dc:date>
    </item>
    <item>
      <title>Re: Need Urgent help! on DAX: Adjustment Needed for Measure to Align with 4-4-5 Calendar</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4666848#M178754</link>
      <description>&lt;P class=""&gt;&lt;STRONG&gt;Hi All,&lt;/STRONG&gt;&lt;/P&gt;&lt;P class=""&gt;I actually found a solution for this but forgot to share it earlier. The measure below works perfectly for my requirement.&lt;/P&gt;&lt;P class=""&gt;Essentially, we needed to track units for the &lt;STRONG&gt;last 7 years&lt;/STRONG&gt;, comparing data from the current period going back exactly 84 months. Initially, the logic worked fine for past years, but now that we’re in &lt;STRONG&gt;2025&lt;/STRONG&gt;, the comparison was incorrectly using the &lt;STRONG&gt;entire calendar year (Jan–Dec)&lt;/STRONG&gt; of 2025 against the last six full years — which doesn't align with the requirement.&lt;/P&gt;&lt;P class=""&gt;However, with the new measure, it now calculates correctly — taking &lt;STRONG&gt;date-to-date logic&lt;/STRONG&gt; into account. For example, as of &lt;STRONG&gt;24th April 2025&lt;/STRONG&gt;, it pulls data going back exactly to &lt;STRONG&gt;24th May 2019&lt;/STRONG&gt;, covering the &lt;STRONG&gt;last 84 months&lt;/STRONG&gt; precisely which is 7 years.&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Cumulative Units Last &lt;/SPAN&gt;&lt;SPAN&gt;7&lt;/SPAN&gt;&lt;SPAN&gt; Years NEW =&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;TODAY&lt;/SPAN&gt;&lt;SPAN&gt;() &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;-- Get today's actual date&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;CurrentYear&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;YEAR&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt;) &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;-- Extract the current year&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;[Full_Date]&lt;/SPAN&gt;&lt;SPAN&gt;) &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;-- Get the max date in context&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;-- Adjust the max date only if the report is showing the current year&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;AdjustedMaxDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;IF&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt; &amp;gt; &lt;/SPAN&gt;&lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp;&amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;YEAR&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt;) = &lt;/SPAN&gt;&lt;SPAN&gt;CurrentYear&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;TodayDate&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;CurrentMaxDate&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;-- Calculate the start date (7 years before the adjusted max date)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;StartDate&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;EDATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;AdjustedMaxDate&lt;/SPAN&gt;&lt;SPAN&gt;, -&lt;/SPAN&gt;&lt;SPAN&gt;84&lt;/SPAN&gt;&lt;SPAN&gt;) &amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;RETURN&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;[Units]&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;ALL&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;[Full_Date]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;gt;= &lt;/SPAN&gt;&lt;SPAN&gt;StartDate&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp;&amp;amp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;DIM_TIME&lt;/SPAN&gt;&lt;SPAN&gt;[Full_Date]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt;= &lt;/SPAN&gt;&lt;SPAN&gt;AdjustedMaxDate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 24 Apr 2025 13:16:44 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-Urgent-help-on-DAX-Adjustment-Needed-for-Measure-to-Align/m-p/4666848#M178754</guid>
      <dc:creator>Srinivas904</dc:creator>
      <dc:date>2025-04-24T13:16:44Z</dc:date>
    </item>
  </channel>
</rss>

