<?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 Calculate Sales based on Fiscal Month and Calendar Month in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculate-Sales-based-on-Fiscal-Month-and-Calendar-Month/m-p/1837122#M39151</link>
    <description>&lt;P&gt;Can any one explain how to Calcualte total sales by fiscal month and calendar month?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have Sales Table which is at Date level and Date table which has both Calendar Month and Fiscal Month.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 12 May 2021 00:43:10 GMT</pubDate>
    <dc:creator>SridharAkidi</dc:creator>
    <dc:date>2021-05-12T00:43:10Z</dc:date>
    <item>
      <title>Calculate Sales based on Fiscal Month and Calendar Month</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculate-Sales-based-on-Fiscal-Month-and-Calendar-Month/m-p/1837122#M39151</link>
      <description>&lt;P&gt;Can any one explain how to Calcualte total sales by fiscal month and calendar month?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have Sales Table which is at Date level and Date table which has both Calendar Month and Fiscal Month.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 May 2021 00:43:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculate-Sales-based-on-Fiscal-Month-and-Calendar-Month/m-p/1837122#M39151</guid>
      <dc:creator>SridharAkidi</dc:creator>
      <dc:date>2021-05-12T00:43:10Z</dc:date>
    </item>
    <item>
      <title>Re: Calculate Sales based on Fiscal Month and Calendar Month</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculate-Sales-based-on-Fiscal-Month-and-Calendar-Month/m-p/1837309#M39155</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="301492" data-lia-user-login="SridharAkidi" class="lia-mention lia-mention-user"&gt;SridharAkidi&lt;/a&gt; , If fiscal month is not the same as a calendar month &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This month last month Calendar&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD('Date'[Date]))&lt;BR /&gt;last MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))&lt;BR /&gt;last month Sales = CALCULATE(SUM(Sales[Sales Amount]),previousmonth('Date'[Date]))&lt;BR /&gt;next month Sales = CALCULATE(SUM(Sales[Sales Amount]),nextmonth('Date'[Date]))&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;FY Month/Period&lt;/P&gt;
&lt;P&gt;You need a new column on YYYYPP or period start Date&lt;/P&gt;
&lt;P&gt;Period Rank = RANKX(all('Period'),'Period'[year period],,ASC,Dense)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;measure &lt;BR /&gt;This Period = CALCULATE(sum('order'[Qty]), FILTER(ALL('Period'),'Period'[Period Rank]=max('Period'[Period Rank])))&lt;BR /&gt;Last Period = CALCULATE(sum('order'[Qty]), FILTER(ALL('Period'),'Period'[Period Rank]=max('Period'[Period Rank])-1))&lt;/P&gt;
&lt;P&gt;Last Year Period = CALCULATE(sum('order'[Qty]), FILTER(ALL('Period'),'Period'[Period]=max('Period'[Period]) &amp;amp;&amp;amp; 'Period'[Year]=max('Period'[Year])-1))&lt;/P&gt;</description>
      <pubDate>Wed, 12 May 2021 02:53:49 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculate-Sales-based-on-Fiscal-Month-and-Calendar-Month/m-p/1837309#M39155</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2021-05-12T02:53:49Z</dc:date>
    </item>
  </channel>
</rss>

