<?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: 3 m rolling in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3944093#M153291</link>
    <description>&lt;P&gt;Sorry for reopening this post.&lt;/P&gt;&lt;P&gt;May i know how to change below formula please.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;* This formula is summing data if it is falling on same day. That is i wanted to take one value or average value if it is falling on same date please.&amp;nbsp; Any help will be highly appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;PRE&gt;Value =
IF(    MAX('Table'[Date])=MINX(FILTER(ALL('Table'),YEAR('Table'[Date])=YEAR(MAX('Table'[Date]))&amp;amp;&amp;amp;MONTH('Table'[Date])=MONTH(MAX('Table'[Date]))),[Date]),
    SUMX('Table',[Total]),0)&lt;/PRE&gt;&lt;/DIV&gt;</description>
    <pubDate>Mon, 03 Jun 2024 17:21:08 GMT</pubDate>
    <dc:creator>jimpatel</dc:creator>
    <dc:date>2024-06-03T17:21:08Z</dc:date>
    <item>
      <title>3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3878876#M151427</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for looking at my post.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I got stuck with 3 months rolling formula and any help will be much appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have data and i wanted to sum the rolling 3 months please.&amp;nbsp;&lt;/P&gt;&lt;P&gt;In this instance in below data,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;3M rolling for Mar 2024 will be 35 ( 30 + 3 +2)&lt;/P&gt;&lt;P&gt;3M rolling for Feb 2024 will be 30 (3+2+25)&lt;/P&gt;&lt;P&gt;3M rolling for Jan 2024 will be 27 (0+25+2) and so on....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Data snapshot:&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;3m rolling which is wrong:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Formula used for 3m rolling :&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;any idea please?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks a lot&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2024 10:01:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3878876#M151427</guid>
      <dc:creator>jimpatel</dc:creator>
      <dc:date>2024-04-30T10:01:55Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879216#M151434</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;RollingSum3Months = 
VAR CurrentDate = MAX('YourDateColumn')
RETURN
    CALCULATE(
        SUM('YourValueColumn'),
        DATESINPERIOD (
           Calendar[Date],
           LASTDATE ( PREVIOUSMONTH ( Calendar[Date] ) ),
           -3, MONTH
    )
    )&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2024 11:49:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879216#M151434</guid>
      <dc:creator>aduguid</dc:creator>
      <dc:date>2024-04-30T11:49:54Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879263#M151438</link>
      <description>&lt;P&gt;Thanks for your reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But i am still getting wrong answer. Am i doing anything wrong here pleasE?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have used above formula in both column and measure and still no luck &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&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;</description>
      <pubDate>Tue, 30 Apr 2024 11:23:16 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879263#M151438</guid>
      <dc:creator>jimpatel</dc:creator>
      <dc:date>2024-04-30T11:23:16Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879353#M151443</link>
      <description>&lt;P&gt;I've updated my answer. Hope this helps.&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2024 11:50:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879353#M151443</guid>
      <dc:creator>aduguid</dc:creator>
      <dc:date>2024-04-30T11:50:39Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879394#M151446</link>
      <description>&lt;P&gt;Much appreciated but i am getting below&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;May i know what i am doing wrong pleasE?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2024 12:03:37 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879394#M151446</guid>
      <dc:creator>jimpatel</dc:creator>
      <dc:date>2024-04-30T12:03:37Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879614#M151452</link>
      <description>&lt;P&gt;Any idea of where i am going wrong please?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot again&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2024 13:03:23 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3879614#M151452</guid>
      <dc:creator>jimpatel</dc:creator>
      <dc:date>2024-04-30T13:03:23Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3881428#M151505</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for the reply from &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="81736" data-lia-user-login="aduguid" class="lia-mention lia-mention-user"&gt;aduguid&lt;/a&gt;&amp;nbsp;, please allow me to provide another insight: &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hi&amp;nbsp; &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="413988" data-lia-user-login="jimpatel" class="lia-mention lia-mention-user"&gt;jimpatel&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Here are the steps you can follow：&lt;/P&gt;
&lt;P&gt;1. Create measure.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Value =
IF(    MAX('Table'[Date])=MINX(FILTER(ALL('Table'),YEAR('Table'[Date])=YEAR(MAX('Table'[Date]))&amp;amp;&amp;amp;MONTH('Table'[Date])=MONTH(MAX('Table'[Date]))),[Date]),
    SUMX('Table',[Total]),0)&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;3 m rolling =
var _enddate=EOMONTH(MAX('Table'[Date]),0)
var _startdate=EOMONTH(MAX('Table'[Date]),-3)
RETURN
SUMX(
    FILTER(ALL('Table'),
    'Table'[Date]&amp;gt;=_startdate&amp;amp;&amp;amp;'Table'[Date]&amp;lt;=_enddate),
[Value])&lt;/LI-CODE&gt;
&lt;P&gt;2. Result:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;/P&gt;
&lt;P&gt;Liu Yang&lt;/P&gt;
&lt;P&gt;If this post &lt;STRONG&gt;helps&lt;/STRONG&gt;, then please consider &lt;EM&gt;Accept it as the solution&lt;/EM&gt; to help the other members find it more quickly&lt;/P&gt;</description>
      <pubDate>Wed, 01 May 2024 05:44:27 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3881428#M151505</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-05-01T05:44:27Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3881994#M151517</link>
      <description>&lt;P&gt;Perfect&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot for your kind help &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 01 May 2024 09:27:05 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3881994#M151517</guid>
      <dc:creator>jimpatel</dc:creator>
      <dc:date>2024-05-01T09:27:05Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3882743#M151535</link>
      <description>&lt;P&gt;Sorry for reopening this post.&lt;/P&gt;&lt;P&gt;May i know how to change below formula please.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;* This formula is summing data if it is falling on same day. That is i wanted to take one value or average value if it is falling on same date please.&amp;nbsp; Any help will be highly appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Value = IF( MAX('Table'[Date])=MINX(FILTER(ALL('Table'),YEAR('Table'[Date])=YEAR(MAX('Table'[Date]))&amp;amp;&amp;amp;MONTH('Table'[Date])=MONTH(MAX('Table'[Date]))),[Date]), SUMX('Table',[Total]),0)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The reason i found is , if 2 rows fall in the minimum criteria the code is adding those values. Is there anyway to not to do that pleasE?&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;Thanks a lot&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;PRE&gt;&amp;nbsp;&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 21 May 2024 14:14:13 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3882743#M151535</guid>
      <dc:creator>jimpatel</dc:creator>
      <dc:date>2024-05-21T14:14:13Z</dc:date>
    </item>
    <item>
      <title>Re: 3 m rolling</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3944093#M153291</link>
      <description>&lt;P&gt;Sorry for reopening this post.&lt;/P&gt;&lt;P&gt;May i know how to change below formula please.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;* This formula is summing data if it is falling on same day. That is i wanted to take one value or average value if it is falling on same date please.&amp;nbsp; Any help will be highly appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;PRE&gt;Value =
IF(    MAX('Table'[Date])=MINX(FILTER(ALL('Table'),YEAR('Table'[Date])=YEAR(MAX('Table'[Date]))&amp;amp;&amp;amp;MONTH('Table'[Date])=MONTH(MAX('Table'[Date]))),[Date]),
    SUMX('Table',[Total]),0)&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 03 Jun 2024 17:21:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/3-m-rolling/m-p/3944093#M153291</guid>
      <dc:creator>jimpatel</dc:creator>
      <dc:date>2024-06-03T17:21:08Z</dc:date>
    </item>
  </channel>
</rss>

