<?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 Cumulative percentage not showing proper data when used date column from fact table on weekend in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-percentage-not-showing-proper-data-when-used-date/m-p/2259304#M54585</link>
    <description>&lt;P&gt;&lt;SPAN&gt;As mentioned in the subject, the cumulative percentage is showing correct data when the date column from the DimDate table is used, but incorrect data when the date column from the fact table is used.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When the date column is used from the Fact table&lt;/P&gt;&lt;P&gt;DAX:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Percentage Cumulated = 
TOTALMTD (
DIVIDE(SUM('Fact'[Shipped Quantity]),SUM('Fact'[Order Quantity]),0),
DATEADD ( DATESMTD (Fact[Date]), 0, DAY )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Screenshot:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;BR /&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;BR /&gt;Note: The date on XAxis is also from the Fact table&lt;BR /&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;When the date column is used from the DimDate table&lt;/P&gt;&lt;P&gt;DAX:&lt;/P&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Percentage Cumulated =
TOTALMTD (
DIVIDE(SUM('Fact'[Shipped Quantity]),SUM('Fact'[Order Quantity]),0),
DATEADD ( DATESMTD (DimDate[Date]), 0, DAY )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Screenshot:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Note: Date on XAxis is also from&amp;nbsp;DimDate table&lt;/EM&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;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;Can anyone please tell me why this is happening?&lt;/P&gt;</description>
    <pubDate>Wed, 29 Dec 2021 08:48:12 GMT</pubDate>
    <dc:creator>SonaliDhotre</dc:creator>
    <dc:date>2021-12-29T08:48:12Z</dc:date>
    <item>
      <title>Cumulative percentage not showing proper data when used date column from fact table on weekend</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-percentage-not-showing-proper-data-when-used-date/m-p/2259304#M54585</link>
      <description>&lt;P&gt;&lt;SPAN&gt;As mentioned in the subject, the cumulative percentage is showing correct data when the date column from the DimDate table is used, but incorrect data when the date column from the fact table is used.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When the date column is used from the Fact table&lt;/P&gt;&lt;P&gt;DAX:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Percentage Cumulated = 
TOTALMTD (
DIVIDE(SUM('Fact'[Shipped Quantity]),SUM('Fact'[Order Quantity]),0),
DATEADD ( DATESMTD (Fact[Date]), 0, DAY )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Screenshot:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;BR /&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;BR /&gt;Note: The date on XAxis is also from the Fact table&lt;BR /&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;When the date column is used from the DimDate table&lt;/P&gt;&lt;P&gt;DAX:&lt;/P&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Percentage Cumulated =
TOTALMTD (
DIVIDE(SUM('Fact'[Shipped Quantity]),SUM('Fact'[Order Quantity]),0),
DATEADD ( DATESMTD (DimDate[Date]), 0, DAY )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Screenshot:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Note: Date on XAxis is also from&amp;nbsp;DimDate table&lt;/EM&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;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;Can anyone please tell me why this is happening?&lt;/P&gt;</description>
      <pubDate>Wed, 29 Dec 2021 08:48:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-percentage-not-showing-proper-data-when-used-date/m-p/2259304#M54585</guid>
      <dc:creator>SonaliDhotre</dc:creator>
      <dc:date>2021-12-29T08:48:12Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative percentage not showing proper data when used date column from fact table on weekend</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-percentage-not-showing-proper-data-when-used-date/m-p/2259353#M54586</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="301917" data-lia-user-login="SonaliDhotre" class="lia-mention lia-mention-user"&gt;SonaliDhotre&lt;/a&gt; , You should use date table, Do you need MTD? YTD ? or cumulative &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Percentage MTD = &lt;BR /&gt;calculate (&lt;BR /&gt;DIVIDE(SUM('Fact'[Shipped Quantity]),SUM('Fact'[Order Quantity]),0),&lt;BR /&gt;DATESMTD (Date[Date])&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;or&lt;BR /&gt;Percentage YTD= &lt;BR /&gt;calculate (&lt;BR /&gt;DIVIDE(SUM('Fact'[Shipped Quantity]),SUM('Fact'[Order Quantity]),0),&lt;BR /&gt;DATESYTD (Date[Date])&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;or&lt;BR /&gt;Percentage Cumulated = &lt;BR /&gt;calculate (&lt;BR /&gt;DIVIDE(SUM('Fact'[Shipped Quantity]),SUM('Fact'[Order Quantity]),0),&lt;BR /&gt;filter(allselected('Date'),'Date'[date] &amp;lt;=max('Date'[date]))&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;if this does not help&lt;/P&gt;
&lt;P&gt;Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.&lt;/P&gt;</description>
      <pubDate>Wed, 29 Dec 2021 08:58:34 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-percentage-not-showing-proper-data-when-used-date/m-p/2259353#M54586</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2021-12-29T08:58:34Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative percentage not showing proper data when used date column from fact table on weekend</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-percentage-not-showing-proper-data-when-used-date/m-p/2263151#M54773</link>
      <description>&lt;P&gt;Hi &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="301917" data-lia-user-login="SonaliDhotre" class="lia-mention lia-mention-user"&gt;SonaliDhotre&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is caused by the context of measure. In the two formulas you provided, the context is different. One is based on the DimDate table and the other is based on the date of the fact table. DATEADD is a time intelligence function.The result table includes only dates that exist in the&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;dates&amp;nbsp;column.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Best Regards,&lt;BR /&gt;Liang&lt;BR /&gt;If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jan 2022 05:26:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-percentage-not-showing-proper-data-when-used-date/m-p/2263151#M54773</guid>
      <dc:creator>V-lianl-msft</dc:creator>
      <dc:date>2022-01-03T05:26:59Z</dc:date>
    </item>
  </channel>
</rss>

