<?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: Problem with Understanding AllSELECTED in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problem-with-Understanding-AllSELECTED/m-p/837754#M6264</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="143348" data-lia-user-login="HarsimranPWRBI" class="lia-mention lia-mention-user"&gt;HarsimranPWRBI&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Try inserting a var and a return.&amp;nbsp; You need to capture that value outside of the CALCULATE. Also the test is less than or equal. You will have to put back in your table name and measure name.&lt;BR /&gt;Let me know if you have any questions.&lt;BR /&gt;&lt;BR /&gt;If this solves your issues, please mark it as the &lt;STRONG&gt;solution, &lt;/STRONG&gt;so that others can find it easily. &lt;STRONG&gt;Kudos &lt;/STRONG&gt;are nice too.&lt;BR /&gt;Nathaniel&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Running Total (AllSELECTED ) Of Quantity =
VAR _ddate =
    MAX ( 'Calendar'[Date] )
RETURN
    CALCULATE (
        [Total Quantity],
        FILTER ( ALLSELECTED ( 'Calendar' ), 'Calendar'[Date] &amp;lt;= _ddate ) //Less than or equal to
    )&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 05 Nov 2019 18:13:10 GMT</pubDate>
    <dc:creator>Nathaniel_C</dc:creator>
    <dc:date>2019-11-05T18:13:10Z</dc:date>
    <item>
      <title>Problem with Understanding AllSELECTED</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problem-with-Understanding-AllSELECTED/m-p/837357#M6247</link>
      <description>&lt;P&gt;Source Data : &lt;STRONG&gt;&lt;FONT color="#000000"&gt;&lt;A href="https://github.com/Microsoft/sql-server-samples/releases/download/wide-world-importers-v1.0/WideWorldImportersDW-Full.bak" target="_blank" rel="noopener"&gt;WideWorldImportersDW-Full.bak&lt;/A&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;As &lt;STRONG&gt;ALLSELECTED&lt;/STRONG&gt;&amp;nbsp;clears the implicit filter for visual it is used in only and keep explicit filter coming from slicer or other visuals.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Running Total (AllSELECTED ) Of Quantity = CALCULATE([Total Sales Quantity],
FILTER( ALLSELECTED('Dimension Date'),
MAX('Dimension Date'[Date])&amp;gt;='Dimension Date'[Date]
)
)&lt;/LI-CODE&gt;&lt;P&gt;Its hard to understand why below code related to ALLSELECTED in above expression is not re initiating running total for selected calendar year label&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;ALLSELECTED('Dimension Date'[Date])&lt;/LI-CODE&gt;&lt;P&gt;It seems like specifying Dimension Date table only and specific column provide all Dimension Date range for selected calender year and hence re-initiating running total.&lt;/P&gt;&lt;P&gt;If that is the case then how can we re-instate running total while using Calendar year label as slicer.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Harry&lt;/P&gt;</description>
      <pubDate>Tue, 05 Nov 2019 11:34:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problem-with-Understanding-AllSELECTED/m-p/837357#M6247</guid>
      <dc:creator>HarsimranPWRBI</dc:creator>
      <dc:date>2019-11-05T11:34:09Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with Understanding AllSELECTED</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problem-with-Understanding-AllSELECTED/m-p/837754#M6264</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="143348" data-lia-user-login="HarsimranPWRBI" class="lia-mention lia-mention-user"&gt;HarsimranPWRBI&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Try inserting a var and a return.&amp;nbsp; You need to capture that value outside of the CALCULATE. Also the test is less than or equal. You will have to put back in your table name and measure name.&lt;BR /&gt;Let me know if you have any questions.&lt;BR /&gt;&lt;BR /&gt;If this solves your issues, please mark it as the &lt;STRONG&gt;solution, &lt;/STRONG&gt;so that others can find it easily. &lt;STRONG&gt;Kudos &lt;/STRONG&gt;are nice too.&lt;BR /&gt;Nathaniel&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Running Total (AllSELECTED ) Of Quantity =
VAR _ddate =
    MAX ( 'Calendar'[Date] )
RETURN
    CALCULATE (
        [Total Quantity],
        FILTER ( ALLSELECTED ( 'Calendar' ), 'Calendar'[Date] &amp;lt;= _ddate ) //Less than or equal to
    )&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Nov 2019 18:13:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problem-with-Understanding-AllSELECTED/m-p/837754#M6264</guid>
      <dc:creator>Nathaniel_C</dc:creator>
      <dc:date>2019-11-05T18:13:10Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with Understanding AllSELECTED</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problem-with-Understanding-AllSELECTED/m-p/838247#M6288</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="159166" data-lia-user-login="Nathaniel_C" class="lia-mention lia-mention-user"&gt;Nathaniel_C&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for the reply but this one is same expression shared in post without variable.&lt;/P&gt;&lt;P&gt;To be more specific,&amp;nbsp; i'm looking for alternate for ALLSELECTED(table) with ALLSELECTED(&amp;lt;column&amp;gt;,..) that can help me achieve same result.&lt;/P&gt;&lt;P&gt;Just to add more info, i'm using Date hierarchy in Visual and CY label as slicer &amp;amp; while using below code for measure in visual does not re-initiate running total for selected CY&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Running Total (AllSELECTED Date) Of Quantity = 
CALCULATE([Total Sales Quantity],
 FILTER( ALLSELECTED('Dimension Date'[Date])
        ,MAX('Dimension Date'[Date])&amp;gt;='Dimension Date'[Date] 
        )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Harry&lt;/P&gt;</description>
      <pubDate>Wed, 06 Nov 2019 06:07:21 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problem-with-Understanding-AllSELECTED/m-p/838247#M6288</guid>
      <dc:creator>HarsimranPWRBI</dc:creator>
      <dc:date>2019-11-06T06:07:21Z</dc:date>
    </item>
  </channel>
</rss>

