<?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: How to show value from Max week selected in the filter as total column? in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073135#M161712</link>
    <description>&lt;P&gt;st = sales gross acc / (sales gross acc+stock gross)&lt;/P&gt;</description>
    <pubDate>Thu, 01 Aug 2024 08:42:59 GMT</pubDate>
    <dc:creator>JIN23</dc:creator>
    <dc:date>2024-08-01T08:42:59Z</dc:date>
    <item>
      <title>How to show value from Max week selected in the filter as total column?</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073048#M161705</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have calculated sell-through and when I select multiple weeks in the filter, I want to show only sell-through of max week selected as total not sum of everything to calculate..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can I do it?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;What I want is to bring 77.2% as total ST% instead of 5.6%..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Same for the stock gross, I want to bring 503,239,352 instead of sum of everything.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need help!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2024 07:48:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073048#M161705</guid>
      <dc:creator>JIN23</dc:creator>
      <dc:date>2024-08-01T07:48:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to show value from Max week selected in the filter as total column?</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073112#M161710</link>
      <description>&lt;P&gt;Can you please post the text for the ST% measure?&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2024 08:30:26 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073112#M161710</guid>
      <dc:creator>aduguid</dc:creator>
      <dc:date>2024-08-01T08:30:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to show value from Max week selected in the filter as total column?</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073135#M161712</link>
      <description>&lt;P&gt;st = sales gross acc / (sales gross acc+stock gross)&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2024 08:42:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073135#M161712</guid>
      <dc:creator>JIN23</dc:creator>
      <dc:date>2024-08-01T08:42:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to show value from Max week selected in the filter as total column?</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073238#M161717</link>
      <description>&lt;P&gt;Try this measure. This assumes you have a calendar type table setup for the week numbers&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;ST = 
VAR MaxWeek = MAX('YourWeekTable'[WeekColumn]) -- Adjust 'YourWeekTable' and 'WeekColumn' to your table and column names
VAR MaxSalesGrossAcc = 
    CALCULATE(
        SUM('YourTable'[SalesGrossAcc]), 
        'YourWeekTable'[WeekColumn] = MaxWeek
    )
VAR MaxStockGrossAcc = 
    CALCULATE(
        SUM('YourTable'[StockGrossAcc]), 
        'YourWeekTable'[WeekColumn] = MaxWeek
    )
VAR SalesGrossAcc = SUM('YourTable'[SalesGrossAcc])
VAR StockGrossAcc = SUM('YourTable'[StockGrossAcc]), 
VAR MaxSellThroughPercentage = DIVIDE(MaxSalesGrossAcc, MaxSalesGrossAcc + StockGrossAcc)
VAR SellThroughPercentage = DIVIDE(SalesGrossAcc, SalesGrossAcc + StockGrossAcc)

RETURN
    IF(
        HASONEVALUE('YourWeekTable'[WeekColumn]),
        SellThroughPercentage,
        MaxSellThroughPercentage
    )&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2024 09:22:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/How-to-show-value-from-Max-week-selected-in-the-filter-as-total/m-p/4073238#M161717</guid>
      <dc:creator>aduguid</dc:creator>
      <dc:date>2024-08-01T09:22:31Z</dc:date>
    </item>
  </channel>
</rss>

