<?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: SPD share Calculation in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2316943#M57746</link>
    <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;&amp;nbsp; let me try&amp;nbsp; and will update now sir&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 03 Feb 2022 06:14:22 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2022-02-03T06:14:22Z</dc:date>
    <item>
      <title>SPD share Calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315141#M57651</link>
      <description>&lt;P&gt;&amp;nbsp;i have table name called Master DB .&amp;nbsp; My table&amp;nbsp; data looks like the below .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Category Dec&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Market name&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Actuals&lt;/P&gt;&lt;P&gt;&amp;nbsp;Cigarettes&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; AZ&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 500&lt;/P&gt;&lt;P&gt;&amp;nbsp;Cigarettes&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; AU&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 300&lt;/P&gt;&lt;P&gt;&amp;nbsp;Cigarettes&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;ZM&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 200&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; RRP&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;AZ&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 600&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; RRP&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; AU&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 100&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; RRP&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;ZM&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 350&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want calcualte SPD share&amp;nbsp; for individual&amp;nbsp;&amp;nbsp;Market name total of the&amp;nbsp;&amp;nbsp;individual&amp;nbsp; &amp;nbsp;Category Dec&amp;nbsp; &amp;nbsp;actuals&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if suppose&amp;nbsp; going to calculate spd share for&amp;nbsp; AZ&amp;nbsp; for&amp;nbsp;&amp;nbsp;Cigarettes&amp;nbsp; category .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cigarettes&amp;nbsp; totalactuals =1000&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;AZ&amp;nbsp; value for&amp;nbsp;&amp;nbsp;Category = 500&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;my calculation should be like&lt;/P&gt;&lt;P&gt;&amp;nbsp;SPD share = ( selected&amp;nbsp;Category Dec&amp;nbsp; &amp;nbsp;total - selected marketname value) /&amp;nbsp;selected&amp;nbsp;Category Dec&amp;nbsp; &amp;nbsp;total&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Example :&amp;nbsp; SPD share =(1000-500)/ 1000&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i have created formula below&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SPD SHARE =&lt;/P&gt;&lt;P&gt;VAR selectedSPD =&lt;BR /&gt;SELECTEDVALUE ( 'Master DB'[Category Dec] )&lt;BR /&gt;VAR totalsum =&lt;BR /&gt;CALCULATE ( SUM ( 'Master DB'[Actuals] ), ALL ( 'Master DB' ) )&lt;BR /&gt;VAR selected_spddesc_value =&lt;BR /&gt;CALCULATE ( SUM ( 'Master DB'[Actuals] ), 'Master DB'[Category Dec] = selectedSPD )&lt;BR /&gt;RETURN&lt;BR /&gt;DIVIDE ( ( selected_spddesc_value - totalsum ), selected_spddesc_value )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But its taking whole actuals value . i want selected actuals value for the calcualtion.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks in advance .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Feb 2022 12:52:06 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315141#M57651</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-02-02T12:52:06Z</dc:date>
    </item>
    <item>
      <title>Re: SPD share Calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315233#M57656</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt; , Not able get that 100 -500/100 &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;but need be like&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SPD SHARE =&lt;/P&gt;
&lt;P&gt;VAR selectedSPD =&lt;BR /&gt;SELECTEDVALUE &lt;BR /&gt;VAR totalsum =&lt;BR /&gt;CALCULATE ( SUM ( 'Master DB'[Actuals] ), ALL ( 'Master DB' ) )&lt;BR /&gt;VAR _select_cat =&lt;BR /&gt;CALCULATE ( SUM ( 'Master DB'[Actuals] ), 'Master DB'[Category Dec] = max( 'Master DB'[Category Dec] ) )&lt;BR /&gt;VAR _select_mar =&lt;BR /&gt;CALCULATE ( SUM ( 'Master DB'[Actuals] ), 'Master DB'[ Market name] = max( 'Master DB'[ Market name] ) )&lt;BR /&gt;RETURN&lt;BR /&gt;DIVIDE ( ( _select_cat - _select_mar ), totalsum )&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Feb 2022 11:55:51 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315233#M57656</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2022-02-02T11:55:51Z</dc:date>
    </item>
    <item>
      <title>Re: SPD share Calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315366#M57658</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;&amp;nbsp; sir&amp;nbsp;&amp;nbsp;&lt;STRONG&gt;Not able get that 1000 -500/1000&amp;nbsp; &amp;nbsp;&lt;BR /&gt;&lt;/STRONG&gt;For example 1000&amp;nbsp; -&amp;nbsp; this is&amp;nbsp; total value for selected&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;Cigarettes&lt;/SPAN&gt; category desc&amp;nbsp; .&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;500 - selected market value .&lt;/P&gt;&lt;P&gt;&amp;nbsp;let me use above&amp;nbsp; your mentiond measure&amp;nbsp; sir&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Feb 2022 12:56:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315366#M57658</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-02-02T12:56:25Z</dc:date>
    </item>
    <item>
      <title>Re: SPD share Calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315374#M57659</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;&amp;nbsp; sir i am getting&amp;nbsp;Failed to resolve name 'SELECTEDVALUE'. It is not a valid table, variable, or function name error&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Feb 2022 13:02:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315374#M57659</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-02-02T13:02:09Z</dc:date>
    </item>
    <item>
      <title>Re: SPD share Calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315390#M57662</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt; ,&lt;/P&gt;
&lt;P&gt;That will be&lt;/P&gt;
&lt;P&gt;New measure =&lt;/P&gt;
&lt;P&gt;var _cat = CALCULATE ( SUM ( 'Master DB'[Actuals] ), 'Master DB'[Category Dec] = max( 'Master DB'[Category Dec] ) )&lt;/P&gt;
&lt;P&gt;var _self = SUM ( 'Master DB'[Actuals] )&lt;/P&gt;
&lt;P&gt;return&lt;/P&gt;
&lt;P&gt;divide(_cat -_self,_cat)&lt;/P&gt;</description>
      <pubDate>Wed, 02 Feb 2022 13:14:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2315390#M57662</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2022-02-02T13:14:45Z</dc:date>
    </item>
    <item>
      <title>Re: SPD share Calculation</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2316943#M57746</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;&amp;nbsp; let me try&amp;nbsp; and will update now sir&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Feb 2022 06:14:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/SPD-share-Calculation/m-p/2316943#M57746</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-02-03T06:14:22Z</dc:date>
    </item>
  </channel>
</rss>

