<?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: Get the last non blank value based on two columns in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Get-the-last-non-blank-value-based-on-two-columns/m-p/2083486#M47321</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;this did the trick:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Real_ = LASTNONBLANKVALUE('Sample'[Week], SUM('Sample'[Real]))&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Target_ = LASTNONBLANKVALUE('Sample'[Real], SUM('Sample'[Target]))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;img /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;If this helped, please mark it as the solution, thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Fri, 17 Sep 2021 20:45:32 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2021-09-17T20:45:32Z</dc:date>
    <item>
      <title>Get the last non blank value based on two columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Get-the-last-non-blank-value-based-on-two-columns/m-p/2083200#M47299</link>
      <description>&lt;P&gt;Hello!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have the following table (It's just one table. I screenshoted in different places) that I want to summarize based on the last value of two columns (Real and Target), producing other two columns in the new table with these new values.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Until now, I was only able to get the last value from the real column.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;SUMMARY = 
SUMMARIZE(Append1, Append1[NAME], "Real", LASTNONBLANKVALUE(Append1[Week], SUM(Append1[Real])))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;However, I also need to get the last value from the "Target" column, also based on the last value of the "Real" column.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So we would get something like this&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;NAME&lt;/TD&gt;&lt;TD&gt;Real&lt;/TD&gt;&lt;TD&gt;Target&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;FER&lt;/TD&gt;&lt;TD&gt;510&lt;/TD&gt;&lt;TD&gt;945&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;MON&lt;/TD&gt;&lt;TD&gt;689&lt;/TD&gt;&lt;TD&gt;530&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Transferência de Peças&lt;/TD&gt;&lt;TD&gt;400&lt;/TD&gt;&lt;TD&gt;715&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As you see above, the last update was made in W34 for "FER" and "MON" and in W36 for "Transferência de Peças".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any idea on how to get the result above?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you in advance&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 16:39:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Get-the-last-non-blank-value-based-on-two-columns/m-p/2083200#M47299</guid>
      <dc:creator>Vinagre01</dc:creator>
      <dc:date>2021-09-17T16:39:00Z</dc:date>
    </item>
    <item>
      <title>Re: Get the last non blank value based on two columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Get-the-last-non-blank-value-based-on-two-columns/m-p/2083486#M47321</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;this did the trick:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Real_ = LASTNONBLANKVALUE('Sample'[Week], SUM('Sample'[Real]))&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Target_ = LASTNONBLANKVALUE('Sample'[Real], SUM('Sample'[Target]))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;img /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;If this helped, please mark it as the solution, thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 17 Sep 2021 20:45:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Get-the-last-non-blank-value-based-on-two-columns/m-p/2083486#M47321</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-09-17T20:45:32Z</dc:date>
    </item>
  </channel>
</rss>

