<?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 Measure that sums based on the values of certain columns in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-that-sums-based-on-the-values-of-certain-columns/m-p/2593308#M74763</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sorry if I put this at the wrong place, or something is unclear, I'm a newbie.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also couldn't find a similar problem unfortunately.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Problem explanation:&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to write a measure that will return the sum of certain values based on two columns.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below you can see how the data is formatted. In this dataset there are two (but could later be more) unique references, I want to sum the cost of the highest recommendations (based on the number in that cell: "recommendation &lt;STRONG&gt;3&lt;/STRONG&gt;:"). So it would take just one value per reference to sum. In this case the measure should sum the 1000 and the 1500 since they respectively have the highest recommendation number of this dataset.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried adding a calculated column with just the recommendation number and then running the calculation with that. But I couldn't figure out how to make a measure that sum's based on these two conditions. (I did this within the power query by copying that column to create a new column and slicing it so i only keep the number). Unfortunately also with this I couldn't make it to work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Curious if this is possible and how I could approach this best, I am looking forward to your feedback!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot in advance and let me know if something is unclear &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some sample data to visualize it:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Reference&lt;/TD&gt;&lt;TD&gt;Recommendations&lt;/TD&gt;&lt;TD&gt;cost&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1404BC_20_&lt;/TD&gt;&lt;TD&gt;recommendation 1: lorem itsem&lt;/TD&gt;&lt;TD&gt;500&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1404BC_20_&lt;/TD&gt;&lt;TD&gt;recommendation 2: lorem itsem&lt;/TD&gt;&lt;TD&gt;850&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1404BC_20_&lt;/TD&gt;&lt;TD&gt;recommendation 3: lorem itsem&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 1: lorem itsem&lt;/TD&gt;&lt;TD&gt;400&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 2: lorem itsem&lt;/TD&gt;&lt;TD&gt;900&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 3: lorem itsem&lt;/TD&gt;&lt;TD&gt;1100&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 4: lorem itsem&lt;/TD&gt;&lt;TD&gt;1500&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;</description>
    <pubDate>Tue, 21 Jun 2022 21:29:34 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2022-06-21T21:29:34Z</dc:date>
    <item>
      <title>Measure that sums based on the values of certain columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-that-sums-based-on-the-values-of-certain-columns/m-p/2593308#M74763</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sorry if I put this at the wrong place, or something is unclear, I'm a newbie.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also couldn't find a similar problem unfortunately.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Problem explanation:&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to write a measure that will return the sum of certain values based on two columns.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below you can see how the data is formatted. In this dataset there are two (but could later be more) unique references, I want to sum the cost of the highest recommendations (based on the number in that cell: "recommendation &lt;STRONG&gt;3&lt;/STRONG&gt;:"). So it would take just one value per reference to sum. In this case the measure should sum the 1000 and the 1500 since they respectively have the highest recommendation number of this dataset.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried adding a calculated column with just the recommendation number and then running the calculation with that. But I couldn't figure out how to make a measure that sum's based on these two conditions. (I did this within the power query by copying that column to create a new column and slicing it so i only keep the number). Unfortunately also with this I couldn't make it to work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Curious if this is possible and how I could approach this best, I am looking forward to your feedback!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot in advance and let me know if something is unclear &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some sample data to visualize it:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Reference&lt;/TD&gt;&lt;TD&gt;Recommendations&lt;/TD&gt;&lt;TD&gt;cost&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1404BC_20_&lt;/TD&gt;&lt;TD&gt;recommendation 1: lorem itsem&lt;/TD&gt;&lt;TD&gt;500&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1404BC_20_&lt;/TD&gt;&lt;TD&gt;recommendation 2: lorem itsem&lt;/TD&gt;&lt;TD&gt;850&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1404BC_20_&lt;/TD&gt;&lt;TD&gt;recommendation 3: lorem itsem&lt;/TD&gt;&lt;TD&gt;1000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 1: lorem itsem&lt;/TD&gt;&lt;TD&gt;400&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 2: lorem itsem&lt;/TD&gt;&lt;TD&gt;900&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 3: lorem itsem&lt;/TD&gt;&lt;TD&gt;1100&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6308EC_24_&lt;/TD&gt;&lt;TD&gt;recommendation 4: lorem itsem&lt;/TD&gt;&lt;TD&gt;1500&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;</description>
      <pubDate>Tue, 21 Jun 2022 21:29:34 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-that-sums-based-on-the-values-of-certain-columns/m-p/2593308#M74763</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-06-21T21:29:34Z</dc:date>
    </item>
    <item>
      <title>Re: Measure that sums based on the values of certain columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-that-sums-based-on-the-values-of-certain-columns/m-p/2593417#M74765</link>
      <description>&lt;P&gt;sumx(values([Reference),calculate(max[cost)) = 1500+1000=2500&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jun 2022 23:15:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-that-sums-based-on-the-values-of-certain-columns/m-p/2593417#M74765</guid>
      <dc:creator>vapid128</dc:creator>
      <dc:date>2022-06-21T23:15:55Z</dc:date>
    </item>
    <item>
      <title>Re: Measure that sums based on the values of certain columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-that-sums-based-on-the-values-of-certain-columns/m-p/2594156#M74823</link>
      <description>&lt;P&gt;That was easier than I expected. Thanks a lot!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Jun 2022 07:52:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-that-sums-based-on-the-values-of-certain-columns/m-p/2594156#M74823</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-06-22T07:52:32Z</dc:date>
    </item>
  </channel>
</rss>

