<?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: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699836#M81665</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386752" data-lia-user-login="firstch" class="lia-mention lia-mention-user"&gt;firstch&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;do you mean in case of multiple selections or only in the case where all the filter is selected?&lt;/P&gt;</description>
    <pubDate>Mon, 15 Aug 2022 07:43:29 GMT</pubDate>
    <dc:creator>tamerj1</dc:creator>
    <dc:date>2022-08-15T07:43:29Z</dc:date>
    <item>
      <title>Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699684#M81643</link>
      <description>&lt;P&gt;Hi all ,&lt;/P&gt;&lt;P&gt;Is there any way to get last to of value in slicer that is text, then convert to int and use in this DAX&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;my sample data please refer to this post:&lt;A href="https://community.powerbi.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-Last-Year-value-with-this-kind-of-filter/m-p/2693976#M81198" target="_blank"&gt;https://community.powerbi.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-Last-Year-value-with-this-kind-of-filter/m-p/2693976#M81198&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Best Regard&lt;BR /&gt;firstch&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 05:06:43 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699684#M81643</guid>
      <dc:creator>firstch</dc:creator>
      <dc:date>2022-08-15T05:06:43Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699738#M81650</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386752" data-lia-user-login="firstch" class="lia-mention lia-mention-user"&gt;firstch&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Generally, it's a bad idea. There's a much better one. In the table from which your slicer's values come put another column where the entries will already be in the right format and type. You can hide this column as it's going to be&amp;nbsp; meant for your measure(s) only. Then you'll be able to retrieve the number straight from the table instead of calculating it and wasting CPU cycles (making DAX slower and more complex than it needs to be).&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 06:26:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699738#M81650</guid>
      <dc:creator>daXtreme</dc:creator>
      <dc:date>2022-08-15T06:26:17Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699739#M81651</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386752" data-lia-user-login="firstch" class="lia-mention lia-mention-user"&gt;firstch&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;In your code: LEFT ( 'table a'[custom], 2 ) will return 25 for all the rows in the sample data. Would you please provide the eaxpected result as per the same sample data?&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 06:30:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699739#M81651</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-08-15T06:30:18Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699750#M81653</link>
      <description>&lt;P&gt;dear&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;it would be RIGHT&lt;SPAN&gt;&amp;nbsp;( 'table a'[custom])&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;best regard&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;firstch&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 06:35:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699750#M81653</guid>
      <dc:creator>firstch</dc:creator>
      <dc:date>2022-08-15T06:35:32Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699764#M81654</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386752" data-lia-user-login="firstch" class="lia-mention lia-mention-user"&gt;firstch&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Here is a sample file with the solution&amp;nbsp;&lt;A href="https://www.dropbox.com/t/SDqoISRmW1vgAF0a" target="_blank"&gt;https://www.dropbox.com/t/SDqoISRmW1vgAF0a&lt;/A&gt;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;Value Last Year = 
VAR SelectedProductionYear = MAX ( 'Table A'[productionYear] )
VAR SelectedYear = VALUE ( RIGHT ( SelectedProductionYear, 2 ) )
VAR LastProductionYear = LEFT ( SelectedProductionYear, 2 ) &amp;amp; SelectedYear - 2 &amp;amp; "/" &amp;amp; SelectedYear - 1
VAR Result =
    CALCULATE ( 
        SUM ( 'Table A'[value] ),
        'Table A'[productionYear] = LastProductionYear
    )
RETURN
    Result&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 15 Aug 2022 06:49:52 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699764#M81654</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-08-15T06:49:52Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699796#M81662</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="349489" data-lia-user-login="daXtreme" class="lia-mention lia-mention-user"&gt;daXtreme&lt;/a&gt;&amp;nbsp; thankyou for your suggestion&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 07:24:07 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699796#M81662</guid>
      <dc:creator>firstch</dc:creator>
      <dc:date>2022-08-15T07:24:07Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699825#M81664</link>
      <description>&lt;P&gt;hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;thankyou ,its work for me now, but if it possible that when user&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;select all in filter can you make the lastyear card to be blank?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;best regard&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;firstch&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 07:42:46 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699825#M81664</guid>
      <dc:creator>firstch</dc:creator>
      <dc:date>2022-08-15T07:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699836#M81665</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386752" data-lia-user-login="firstch" class="lia-mention lia-mention-user"&gt;firstch&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;do you mean in case of multiple selections or only in the case where all the filter is selected?&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 07:43:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699836#M81665</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-08-15T07:43:29Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699851#M81666</link>
      <description>&lt;P&gt;HI&lt;/P&gt;&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in case of all filter ,currently when select all its show data of year 2564/65 sir&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;best regard&lt;/P&gt;&lt;P&gt;firstch&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 08:18:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699851#M81666</guid>
      <dc:creator>firstch</dc:creator>
      <dc:date>2022-08-15T08:18:50Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699975#M81677</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="386752" data-lia-user-login="firstch" class="lia-mention lia-mention-user"&gt;firstch&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Sorry, I was not on my desk. Here is the updated file&amp;nbsp;&lt;A href="https://www.dropbox.com/t/oNRuMlL6NSzUdJhu" target="_blank"&gt;https://www.dropbox.com/t/oNRuMlL6NSzUdJhu&lt;/A&gt;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;Value Last Year = 
VAR SelectedProductionYear = MAX ( 'Table A'[productionYear] )
VAR SelectedYear = VALUE ( RIGHT ( SelectedProductionYear, 2 ) )
VAR LastProductionYear = LEFT ( SelectedProductionYear, 2 ) &amp;amp; SelectedYear - 2 &amp;amp; "/" &amp;amp; SelectedYear - 1
VAR Result =
    CALCULATE ( 
        SUM ( 'Table A'[value] ),
        'Table A'[productionYear] = LastProductionYear
    )
RETURN
    IF (
        COUNTROWS ( ALLSELECTED ( 'Table A'[productionYear] ) )
            &amp;lt;&amp;gt; COUNTROWS ( ALL ( 'Table A'[productionYear] ) ),
        Result
    )&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 15 Aug 2022 08:53:26 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2699975#M81677</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-08-15T08:53:26Z</dc:date>
    </item>
    <item>
      <title>Re: Is there any way to get last to of value in slicer that is text, then convert to int and use in dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2700013#M81680</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp; Thankyou so much for your help,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Best Regard&lt;/P&gt;&lt;P&gt;firstch&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 09:19:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Is-there-any-way-to-get-last-to-of-value-in-slicer-that-is-text/m-p/2700013#M81680</guid>
      <dc:creator>firstch</dc:creator>
      <dc:date>2022-08-15T09:19:04Z</dc:date>
    </item>
  </channel>
</rss>

