<?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: Sum only appearance per date and per truck in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-only-appearance-per-date-and-per-truck/m-p/3741718#M145915</link>
    <description>&lt;P&gt;&lt;SPAN&gt;To achieve the expected result in Power BI using DAX, you can create a new measure that calculates the sum of the Allocation only for the first appearance of each unit and project combination on a particular date. You can use the following DAX formula:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;TotalAllocation =&lt;BR /&gt;SUMX(&lt;BR /&gt;SUMMARIZE(&lt;BR /&gt;'YourTableName',&lt;BR /&gt;'YourTableName'[Ship Date],&lt;BR /&gt;'YourTableName'[Unit],&lt;BR /&gt;'YourTableName'[Project],&lt;BR /&gt;"FirstAppearance", MIN('YourTableName'[Allocation])&lt;BR /&gt;),&lt;BR /&gt;[FirstAppearance]&lt;BR /&gt;)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here's how the formula works:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;SUMMARIZE: This function creates a summary table with unique combinations of Ship Date, Unit, and Project. For each combination, it calculates the minimum Allocation value (which represents the first appearance of that combination).&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;SUMX: This function iterates over each row of the summarized table and sums up the FirstAppearance values.&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Make sure to replace 'YourTableName' with the actual name of your table containing the data.&lt;/P&gt;&lt;P&gt;Create a new measure using this DAX formula, and then use this measure in your Power BI report to display the total allocation per project, considering only the first appearance per unit and per date.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If this post&amp;nbsp;helps, then please consider&amp;nbsp;Accepting it as the solution&amp;nbsp;to help the other members find it more quickly.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In case there is still a problem, please feel free and explain your issue in detail,&amp;nbsp;It will be my pleasure to assist you in any way I can.&lt;/STRONG&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 05 Mar 2024 05:13:55 GMT</pubDate>
    <dc:creator>123abc</dc:creator>
    <dc:date>2024-03-05T05:13:55Z</dc:date>
    <item>
      <title>Sum only appearance per date and per truck</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-only-appearance-per-date-and-per-truck/m-p/3741674#M145914</link>
      <description>&lt;P&gt;Hi guys&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to create a table to sum up the freight per project. The data base has duplicate projects per unit and I have created a measure to allocate the freight per project without considering the duplicates.&lt;/P&gt;&lt;P&gt;In the following exemple,&amp;nbsp; for the first unit "Truck 1" Date 2/1/24, Client 1 repeats 3 times, to calculate the allocation it was counted only once but it has a value anyways. For the table I'm trying to create I need to sum up the allocation only the first appearance per unit and per date.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Mar 2024 04:19:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-only-appearance-per-date-and-per-truck/m-p/3741674#M145914</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-03-05T04:19:20Z</dc:date>
    </item>
    <item>
      <title>Re: Sum only appearance per date and per truck</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-only-appearance-per-date-and-per-truck/m-p/3741718#M145915</link>
      <description>&lt;P&gt;&lt;SPAN&gt;To achieve the expected result in Power BI using DAX, you can create a new measure that calculates the sum of the Allocation only for the first appearance of each unit and project combination on a particular date. You can use the following DAX formula:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;TotalAllocation =&lt;BR /&gt;SUMX(&lt;BR /&gt;SUMMARIZE(&lt;BR /&gt;'YourTableName',&lt;BR /&gt;'YourTableName'[Ship Date],&lt;BR /&gt;'YourTableName'[Unit],&lt;BR /&gt;'YourTableName'[Project],&lt;BR /&gt;"FirstAppearance", MIN('YourTableName'[Allocation])&lt;BR /&gt;),&lt;BR /&gt;[FirstAppearance]&lt;BR /&gt;)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here's how the formula works:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;SUMMARIZE: This function creates a summary table with unique combinations of Ship Date, Unit, and Project. For each combination, it calculates the minimum Allocation value (which represents the first appearance of that combination).&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;SUMX: This function iterates over each row of the summarized table and sums up the FirstAppearance values.&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Make sure to replace 'YourTableName' with the actual name of your table containing the data.&lt;/P&gt;&lt;P&gt;Create a new measure using this DAX formula, and then use this measure in your Power BI report to display the total allocation per project, considering only the first appearance per unit and per date.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If this post&amp;nbsp;helps, then please consider&amp;nbsp;Accepting it as the solution&amp;nbsp;to help the other members find it more quickly.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In case there is still a problem, please feel free and explain your issue in detail,&amp;nbsp;It will be my pleasure to assist you in any way I can.&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Mar 2024 05:13:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-only-appearance-per-date-and-per-truck/m-p/3741718#M145915</guid>
      <dc:creator>123abc</dc:creator>
      <dc:date>2024-03-05T05:13:55Z</dc:date>
    </item>
    <item>
      <title>Re: Sum only appearance per date and per truck</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-only-appearance-per-date-and-per-truck/m-p/3744264#M146009</link>
      <description>&lt;P&gt;Thank you so much for taking the time to explain every step. It did resolve my issue!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Mar 2024 21:50:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-only-appearance-per-date-and-per-truck/m-p/3744264#M146009</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-03-05T21:50:54Z</dc:date>
    </item>
  </channel>
</rss>

