<?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: Wrong Total in SUMX in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4327889#M171813</link>
    <description>&lt;P&gt;the below is the expected result after modifying your DAX slightly. It works well if the 'Calendar' and&amp;nbsp;&lt;SPAN&gt;'Historical_Prices (fact)' tables are disconnected. Once the relationships are made, it does not work as expected.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I want to know how to make it work while the relationships are active, because I need the relationship for other calculations&lt;/SPAN&gt;&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>Fri, 13 Dec 2024 11:46:36 GMT</pubDate>
    <dc:creator>MohamedSalih_12</dc:creator>
    <dc:date>2024-12-13T11:46:36Z</dc:date>
    <item>
      <title>Wrong Total in SUMX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4323874#M171662</link>
      <description>&lt;P&gt;I have two fact tables&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. Historic Stock prices downloaded from Google sheets with 3 Columns Date, Ticker, Unit Price&lt;/P&gt;&lt;P&gt;2. Stock Buy transactions table with 4 Columns Date, Ticker, Quantity, Unit Price&lt;/P&gt;&lt;P&gt;3. Below is the matrix which contains Date from Calendar Table, Ticker from Bridge Table, Quantity from Transaction table, Last Unit Price from Historical Prices Table with REMOVEFILTERS('Calendar'[Date] applied, all is well so far&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;The issue is with the measure [Amount 2]&lt;SPAN&gt;&amp;nbsp;=&lt;/SPAN&gt; &lt;SPAN&gt;SUM&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Transaction'&lt;/SPAN&gt;&lt;SPAN&gt;[Quantity]&lt;/SPAN&gt;&lt;SPAN&gt;)* &lt;/SPAN&gt;&lt;SPAN&gt;[Last Unit Price]. It works well in the row context of Tickers, but in the context of Date (see 5/7/2024), it multiplies total Quantity with total of the Unit Prices (i.e 392,036.76). &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;But I want in the Date rows summation of product of each ticker which has to be (95,027.12)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I hope I explained the situation well, looking for a corrected measure.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2024 12:50:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4323874#M171662</guid>
      <dc:creator>MohamedSalih_12</dc:creator>
      <dc:date>2024-12-11T12:50:29Z</dc:date>
    </item>
    <item>
      <title>Re: Wrong Total in SUMX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4324692#M171705</link>
      <description>&lt;P&gt;Please provide sample data that covers your issue or question &lt;STRONG&gt;completely&lt;/STRONG&gt;, in a &lt;STRONG&gt;usable&lt;/STRONG&gt; format (not as a screenshot).&lt;BR /&gt;Do not include sensitive information. Do not include anything that is unrelated to the issue or question. &lt;BR /&gt;Please show the expected outcome based on the sample data you provided. &lt;BR /&gt;&lt;BR /&gt;Need help uploading data? &lt;A href="https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216&lt;/A&gt; &lt;BR /&gt;Want faster answers? &lt;A href="https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2024 00:55:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4324692#M171705</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-12-12T00:55:39Z</dc:date>
    </item>
    <item>
      <title>Re: Wrong Total in SUMX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4326075#M171748</link>
      <description>&lt;P&gt;Thank you for your reply&lt;/P&gt;&lt;P&gt;Somehow, I managed to find a solution for the yesterday's problem. Now I am stuck with another one, please find below&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to make a matrix with&amp;nbsp;&lt;BR /&gt;Calendar[Date],&amp;nbsp; &amp;nbsp;Data[Ticker] and I want to add a measure to return the LAST PRICE for each ticker from Historical Prices table in all the Calendar[Date] rows. Also, it must return Blank if that ticker has no transaction in Transaction table in that Date&lt;/P&gt;&lt;P&gt;I managed to achieve the required result with helper table, please help to achieve the same result without the helper table and see the attached pbix file.&amp;nbsp;&amp;nbsp;&lt;A title="PBIX File" href="https://drive.google.com/file/d/1pvIsF2q8_2tp9Wrj8sS6drFvkvS7VWj4/view?usp=sharing" target="_blank" rel="noopener"&gt;https://drive.google.com/file/d/1pvIsF2q8_2tp9Wrj8sS6drFvkvS7VWj4/view?usp=sharing&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My apologies if I could not explain the problem well, please feel free to ask if anything&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2024 13:48:41 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4326075#M171748</guid>
      <dc:creator>MohamedSalih_12</dc:creator>
      <dc:date>2024-12-12T13:48:41Z</dc:date>
    </item>
    <item>
      <title>Re: Wrong Total in SUMX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4326771#M171769</link>
      <description>&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2024 21:23:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4326771#M171769</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-12-12T21:23:00Z</dc:date>
    </item>
    <item>
      <title>Re: Wrong Total in SUMX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4327889#M171813</link>
      <description>&lt;P&gt;the below is the expected result after modifying your DAX slightly. It works well if the 'Calendar' and&amp;nbsp;&lt;SPAN&gt;'Historical_Prices (fact)' tables are disconnected. Once the relationships are made, it does not work as expected.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I want to know how to make it work while the relationships are active, because I need the relationship for other calculations&lt;/SPAN&gt;&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>Fri, 13 Dec 2024 11:46:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4327889#M171813</guid>
      <dc:creator>MohamedSalih_12</dc:creator>
      <dc:date>2024-12-13T11:46:36Z</dc:date>
    </item>
    <item>
      <title>Re: Wrong Total in SUMX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4327979#M171814</link>
      <description>&lt;P&gt;Make the relationship inactive. Use USERELATIONSHIP in your measure.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2024 12:39:43 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4327979#M171814</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-12-13T12:39:43Z</dc:date>
    </item>
    <item>
      <title>Re: Wrong Total in SUMX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4332654#M172003</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="871860" data-lia-user-login="MohamedSalih_12" class="lia-mention lia-mention-user"&gt;MohamedSalih_12&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much&amp;nbsp;lbendlin&amp;nbsp;for your prompt reply.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can you tell me if your problem is solved? If yes, please accept it as solution.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Nono Chen&lt;/P&gt;
&lt;P&gt;If this &lt;STRONG&gt;&lt;EM&gt;post&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;helps, then please consider&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;Accept it as the solution&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;to help the other members find it more quickly.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Dec 2024 08:58:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Wrong-Total-in-SUMX/m-p/4332654#M172003</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-12-17T08:58:55Z</dc:date>
    </item>
  </channel>
</rss>

