<?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 Highest value of a duplicate in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Highest-value-of-a-duplicate/m-p/3176620#M114689</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am new to Power Bi and am trying to find the highest step used for duplicating item IDs. Below is the data I am working with.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Item. &amp;nbsp;Step.&amp;nbsp;&lt;BR /&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&lt;/P&gt;&lt;P&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 2&lt;/P&gt;&lt;P&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;&lt;P&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 4&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 2&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;in this dataset the "item" data is repeated as the items move through different steps. I am only interested in using data from the last step. This is what I would like to filter the table down to&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;item. &amp;nbsp;Step.&amp;nbsp;&lt;BR /&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 4&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Although similar posts exists, these data are different because the item column and the step column both have repeats information. I need to identify the highest step for every single unique item. An additional challenge is the maximum number of steps for different items varies. &amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;how would I go about this?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;similar to: &lt;A href="http://community.powerbi.com/t5/DAX-Commands-and-Tips/Highest-Value-of-duplicate/m-p/1689664" target="_blank" rel="noopener"&gt;http://community.powerbi.com/t5/DAX-Commands-and-Tips/Highest-Value-of-duplicate/m-p/1689664&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;</description>
    <pubDate>Thu, 06 Apr 2023 19:11:36 GMT</pubDate>
    <dc:creator>Lm2712</dc:creator>
    <dc:date>2023-04-06T19:11:36Z</dc:date>
    <item>
      <title>Highest value of a duplicate</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Highest-value-of-a-duplicate/m-p/3176620#M114689</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am new to Power Bi and am trying to find the highest step used for duplicating item IDs. Below is the data I am working with.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Item. &amp;nbsp;Step.&amp;nbsp;&lt;BR /&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&lt;/P&gt;&lt;P&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 2&lt;/P&gt;&lt;P&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;&lt;P&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 4&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 2&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;in this dataset the "item" data is repeated as the items move through different steps. I am only interested in using data from the last step. This is what I would like to filter the table down to&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;item. &amp;nbsp;Step.&amp;nbsp;&lt;BR /&gt;A. &amp;nbsp; &amp;nbsp; &amp;nbsp; 4&lt;/P&gt;&lt;P&gt;B. &amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Although similar posts exists, these data are different because the item column and the step column both have repeats information. I need to identify the highest step for every single unique item. An additional challenge is the maximum number of steps for different items varies. &amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;how would I go about this?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;similar to: &lt;A href="http://community.powerbi.com/t5/DAX-Commands-and-Tips/Highest-Value-of-duplicate/m-p/1689664" target="_blank" rel="noopener"&gt;http://community.powerbi.com/t5/DAX-Commands-and-Tips/Highest-Value-of-duplicate/m-p/1689664&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;</description>
      <pubDate>Thu, 06 Apr 2023 19:11:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Highest-value-of-a-duplicate/m-p/3176620#M114689</guid>
      <dc:creator>Lm2712</dc:creator>
      <dc:date>2023-04-06T19:11:36Z</dc:date>
    </item>
    <item>
      <title>Re: Highest value of a duplicate</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Highest-value-of-a-duplicate/m-p/3176643#M114691</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="542674" data-lia-user-login="Lm2712" class="lia-mention lia-mention-user"&gt;Lm2712&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Place the following measure in the filter pane of your visual, select "is not blank" then apply the filter&amp;nbsp;&lt;/P&gt;
&lt;P&gt;FilterMeasure =&lt;BR /&gt;VAR MaxStep =&lt;BR /&gt;CALCULATE (&lt;BR /&gt;MAX ( 'Table'[Step] ),&lt;BR /&gt;ALLSELECTED ( 'Table' ),&lt;BR /&gt;VALUES ( 'Table'[Item] )&lt;BR /&gt;)&lt;BR /&gt;RETURN&lt;BR /&gt;COUNTROWS ( FILTER ( 'Table', 'Table'[Step] = MaxStep ) )&lt;/P&gt;</description>
      <pubDate>Thu, 06 Apr 2023 19:24:40 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Highest-value-of-a-duplicate/m-p/3176643#M114691</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2023-04-06T19:24:40Z</dc:date>
    </item>
    <item>
      <title>Re: Highest value of a duplicate</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Highest-value-of-a-duplicate/m-p/3176665#M114692</link>
      <description>&lt;P&gt;I hope this would work for you!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Last Step = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN&gt;_Iteam&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;FactTable&lt;/SPAN&gt;&lt;SPAN&gt;[Item]&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt; &lt;SPAN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ubDate>Thu, 06 Apr 2023 19:45:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Highest-value-of-a-duplicate/m-p/3176665#M114692</guid>
      <dc:creator>Ajendra</dc:creator>
      <dc:date>2023-04-06T19:45:59Z</dc:date>
    </item>
  </channel>
</rss>

