<?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: Powerbi Desktop - Line item value Vs. Grand Total in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431710#M26698</link>
    <description>&lt;P&gt;Hey&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As per your description, Grand Total of watch is based on a formula, and I am guessing it is a measure.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this is true, then you can use the measure in your formula:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this is not the case, then please share details on how you are calculating the Grand Total.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers!&lt;BR /&gt;Vivek&lt;BR /&gt;&lt;BR /&gt;Blog: &lt;A href="https://www.vivran.in/my-blog" target="_blank"&gt;vivran.in/my-blog&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://www.linkedin.com/in/vivek-ranjan-063a1a17b/" target="_blank"&gt;Connect on LinkedIn&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://twitter.com/imvivran" target="_blank"&gt;Follow on Twitter&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 14 Oct 2020 01:45:50 GMT</pubDate>
    <dc:creator>vivran22</dc:creator>
    <dc:date>2020-10-14T01:45:50Z</dc:date>
    <item>
      <title>Powerbi Desktop - Line item value Vs. Grand Total</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431352#M26694</link>
      <description>&lt;P&gt;Folks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have the following columns in my report&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Industry&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; Watch&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Rating&lt;/P&gt;&lt;P&gt;Agri&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; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;4.3 %&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;/P&gt;&lt;P&gt;Mining&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; &amp;nbsp; &amp;nbsp;3.2&amp;nbsp; %&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&lt;/P&gt;&lt;P&gt;Manufacturing&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1.4&amp;nbsp; %&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&lt;/P&gt;&lt;P&gt;Oil &amp;amp; Gas&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; 6.7&amp;nbsp; %&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;/P&gt;&lt;P&gt;GRAND TOTAL&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;5.6 %&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The Watch is computed using a formula. What I need is if the individual Watch&amp;nbsp; item value &amp;gt; Grand Total, then 2, else 1, as 'Rating'.&amp;nbsp; Is there a way I can store the Grand Total in a 'global' kind of variable, and then compare the individual row value against this global variable and return 1 or 2?&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>Tue, 13 Oct 2020 21:45:42 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431352#M26694</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-10-13T21:45:42Z</dc:date>
    </item>
    <item>
      <title>Re: Powerbi Desktop - Line item value Vs. Grand Total</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431710#M26698</link>
      <description>&lt;P&gt;Hey&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As per your description, Grand Total of watch is based on a formula, and I am guessing it is a measure.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this is true, then you can use the measure in your formula:&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this is not the case, then please share details on how you are calculating the Grand Total.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers!&lt;BR /&gt;Vivek&lt;BR /&gt;&lt;BR /&gt;Blog: &lt;A href="https://www.vivran.in/my-blog" target="_blank"&gt;vivran.in/my-blog&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://www.linkedin.com/in/vivek-ranjan-063a1a17b/" target="_blank"&gt;Connect on LinkedIn&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://twitter.com/imvivran" target="_blank"&gt;Follow on Twitter&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 14 Oct 2020 01:45:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431710#M26698</guid>
      <dc:creator>vivran22</dc:creator>
      <dc:date>2020-10-14T01:45:50Z</dc:date>
    </item>
    <item>
      <title>Re: Powerbi Desktop - Line item value Vs. Grand Total</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431902#M26701</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="141768" data-lia-user-login="vivran22" class="lia-mention lia-mention-user"&gt;vivran22&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your reply.&amp;nbsp; The Watch is a calculated measure Watch (%) = (sum('Industry'[gloan]+sum('Industry'[wloan]))/sum('Industry'[CurrVal]), based on the Industry columns.&amp;nbsp; As its a matrix report, the Grand Total is enabled from the Format Painter (Sub Totals 'on') and the value is computed and there's&amp;nbsp; no Grand Total measure as such.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 14 Oct 2020 03:44:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431902#M26701</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-10-14T03:44:01Z</dc:date>
    </item>
    <item>
      <title>Re: Powerbi Desktop - Line item value Vs. Grand Total</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431903#M26702</link>
      <description>&lt;P&gt;try this measure&lt;/P&gt;&lt;LI-CODE lang="cpp"&gt;Rating=VAR _WatchTotal=CALCULATE([Watch],ALL('industry'[industry])) RETURN IF([Watch]&amp;lt;_WatchTotal,1,2)&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 14 Oct 2020 03:55:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1431903#M26702</guid>
      <dc:creator>wdx223_Daniel</dc:creator>
      <dc:date>2020-10-14T03:55:09Z</dc:date>
    </item>
    <item>
      <title>Re: Powerbi Desktop - Line item value Vs. Grand Total</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1434424#M26770</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You may try the following measure:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Rating = 
VAR _Overall =
    CALCULATE ( [Watch %], ALL ( Industry[Industry] ) )
VAR _Rating =
    IF ( HASONEVALUE ( Industry[Industry] ), IF ( [Watch %] &amp;gt; _Overall, 2, 1 ) )
RETURN
    _Rating&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;where&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Watch % = 
DIVIDE (
    SUM ( Industry[gloan] ) + SUM ( Industry[wloan] ),
    SUM ( Industry[CurrVal] )
)
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Result:&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;
&lt;P&gt;Cheers!&lt;BR /&gt;Vivek&lt;BR /&gt;&lt;BR /&gt;Blog: &lt;A href="https://www.vivran.in/my-blog" target="_blank"&gt;vivran.in/my-blog&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://www.linkedin.com/in/vivek-ranjan-063a1a17b/" target="_blank"&gt;Connect on LinkedIn&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://twitter.com/imvivran" target="_blank"&gt;Follow on Twitter&lt;/A&gt;&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;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Oct 2020 00:36:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Powerbi-Desktop-Line-item-value-Vs-Grand-Total/m-p/1434424#M26770</guid>
      <dc:creator>vivran22</dc:creator>
      <dc:date>2020-10-15T00:36:32Z</dc:date>
    </item>
  </channel>
</rss>

