<?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: Parent child calculation in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3493945#M133833</link>
    <description>&lt;P&gt;Thank you, the solution works! How and what should be transformed so that I can make it dynamic with a measure?&lt;/P&gt;</description>
    <pubDate>Tue, 24 Oct 2023 13:10:17 GMT</pubDate>
    <dc:creator>borniex</dc:creator>
    <dc:date>2023-10-24T13:10:17Z</dc:date>
    <item>
      <title>Parent child calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3491759#M133699</link>
      <description>&lt;P&gt;Hello!&lt;BR /&gt;It seems like a simple task but I can't figure it out, has anyone encountered this problem?&lt;BR /&gt;I am attaching a clear example.&amp;nbsp;How can I calculate the two columns?&lt;img /&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Oct 2023 15:12:52 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3491759#M133699</guid>
      <dc:creator>borniex</dc:creator>
      <dc:date>2023-10-23T15:12:52Z</dc:date>
    </item>
    <item>
      <title>Re: Parent child calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3492214#M133719</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="185738" data-lia-user-login="borniex" class="lia-mention lia-mention-user"&gt;borniex&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Assuming, the tables are not related in your data model, I could propose to create a couple of calculated columns like this one:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;In plain text:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;sum_parent = 
VAR CurrentParent = [parent] 
RETURN SUMX ( FILTER ( Data, [product] = CurrentParent ), [value] )

sum_child = 
VAR CurrentChild = [child]
RETURN SUMX ( FILTER ( Data, [product] = CurrentChild ), [value] )&lt;/LI-CODE&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size="2"&gt;Best Regards, &lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size="2"&gt;Alexander&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size="2"&gt;&lt;A href="https://youtube.com/@powerbi-vlog" target="_blank"&gt;My YouTube vlog in English&lt;/A&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size="2"&gt;&lt;A href="https://youtube.com/@pbi-vlog" target="_blank"&gt;My YouTube vlog in Russian&lt;/A&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Oct 2023 19:53:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3492214#M133719</guid>
      <dc:creator>barritown</dc:creator>
      <dc:date>2023-10-23T19:53:22Z</dc:date>
    </item>
    <item>
      <title>Re: Parent child calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3493945#M133833</link>
      <description>&lt;P&gt;Thank you, the solution works! How and what should be transformed so that I can make it dynamic with a measure?&lt;/P&gt;</description>
      <pubDate>Tue, 24 Oct 2023 13:10:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3493945#M133833</guid>
      <dc:creator>borniex</dc:creator>
      <dc:date>2023-10-24T13:10:17Z</dc:date>
    </item>
    <item>
      <title>Re: Parent child calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3494281#M133845</link>
      <description>&lt;P&gt;In case you use a table visual for that, such measures will do:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;sum_parent = 
VAR CurrentParent = MIN ( Relationship[parent] )
RETURN SUMX ( FILTER ( Data, [product] = CurrentParent ), [value] )

sum_child = 
VAR CurrentChild = MAX ( Relationship[child] )
RETURN SUMX ( FILTER ( Data, [product] = CurrentChild ), [value] )&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Oct 2023 15:23:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Parent-child-calculation/m-p/3494281#M133845</guid>
      <dc:creator>barritown</dc:creator>
      <dc:date>2023-10-24T15:23:15Z</dc:date>
    </item>
  </channel>
</rss>

