<?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 with 2 x IF in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921266#M75840</link>
    <description>&lt;P&gt;Hi Bruno,&lt;/P&gt;
&lt;P&gt;Thanks for responding &lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Unfortunately that gives ;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Daryn_0-1650614351124.png" style="width: 425px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/77647i31732DBD9F0E5DAA/image-dimensions/425x42?v=v2" width="425" height="42" role="button" title="Daryn_0-1650614351124.png" alt="Daryn_0-1650614351124.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 22 Apr 2022 07:59:28 GMT</pubDate>
    <dc:creator>Daryn</dc:creator>
    <dc:date>2022-04-22T07:59:28Z</dc:date>
    <item>
      <title>SUM with 2 x IF</title>
      <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921229#M75837</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I have a table with Dimension for customer &amp;amp; currency. I then have measures summing values (one for UK spend, one for GmbH spend).&lt;/P&gt;
&lt;P&gt;We have a basic preset internal transaction exchange rate (say 1.2 for now).&lt;/P&gt;
&lt;P&gt;I can convert the GBP using-&lt;/P&gt;
&lt;P&gt;Sum ({&amp;lt;WAERK = {'GBP'}&amp;gt;}[ZDE_UMSATZ.NETWR]) + Sum ({&amp;lt;WAERK = {'GBP'}&amp;gt;}NETWR) * 1.2&lt;/P&gt;
&lt;P&gt;(blacked out names).&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Daryn_0-1650611874339.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/77630i815A6CB9B8E5CA91/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Daryn_0-1650611874339.png" alt="Daryn_0-1650611874339.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I then tried to turn the expression into a SUM IF. So that the last column 'Totals in €' will include the € currency values as they are ) no multiplication or such.&lt;/P&gt;
&lt;P&gt;At some point I will look to include another IF for the $ currency values, but that hasn't got to be now!&lt;/P&gt;
&lt;P&gt;WAERK = currency&lt;/P&gt;
&lt;P&gt;ZDE_UMSATZ.NETWR = GmbH values&lt;/P&gt;
&lt;P&gt;NETWR =&amp;nbsp; UK values&lt;/P&gt;
&lt;P&gt;My currencies are as in the table 'GBP', 'EUR', 'USD'&lt;/P&gt;
&lt;P&gt;I thought the below would be correct, but it isn't.&lt;/P&gt;
&lt;P&gt;=SUM (IF (WAERK -= {'EUR'},[ZDE_UMSATZ.NETWR]+[NETWR]*1.2), IF (WAERK = {'EUR'},[ZDE_UMSATZ.NETWR]+[NETWR]))&lt;/P&gt;
&lt;P&gt;I hope that makes sense! Thanks as always for any advice or solution.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Happy Friday!&lt;/P&gt;
&lt;P&gt;Regards, Daryn.&lt;/P&gt;</description>
      <pubDate>Fri, 22 Apr 2022 07:25:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921229#M75837</guid>
      <dc:creator>Daryn</dc:creator>
      <dc:date>2022-04-22T07:25:02Z</dc:date>
    </item>
    <item>
      <title>Re: SUM with 2 x IF</title>
      <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921261#M75839</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;/P&gt;
&lt;P&gt;may be this&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;=SUM (IF (WAERK -= {'EUR'},[ZDE_UMSATZ.NETWR]+[NETWR]*1.2), IF (WAERK = {'EUR'},[ZDE_UMSATZ.NETWR]+[NETWR]))&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;sum( if( WAERK&amp;lt;&amp;gt;'EUR',&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;[ZDE_UMSATZ.NETWR]+[NETWR]*1.2),&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;if(WAERK='EUR' ,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;ZDE_UMSATZ.NETWR]+[NETWR]))&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Apr 2022 07:54:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921261#M75839</guid>
      <dc:creator>brunobertels</dc:creator>
      <dc:date>2022-04-22T07:54:27Z</dc:date>
    </item>
    <item>
      <title>Re: SUM with 2 x IF</title>
      <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921266#M75840</link>
      <description>&lt;P&gt;Hi Bruno,&lt;/P&gt;
&lt;P&gt;Thanks for responding &lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Unfortunately that gives ;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Daryn_0-1650614351124.png" style="width: 425px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/77647i31732DBD9F0E5DAA/image-dimensions/425x42?v=v2" width="425" height="42" role="button" title="Daryn_0-1650614351124.png" alt="Daryn_0-1650614351124.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Apr 2022 07:59:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921266#M75840</guid>
      <dc:creator>Daryn</dc:creator>
      <dc:date>2022-04-22T07:59:28Z</dc:date>
    </item>
    <item>
      <title>Re: SUM with 2 x IF</title>
      <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921319#M75844</link>
      <description>&lt;P&gt;Hoi&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sorry my bad&amp;nbsp;&lt;/P&gt;
&lt;P&gt;so may be this&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;IF(WAERK='EUR',SUM([ZDE_UMSATZ.NETWR]) + SUM([NETWR]),IF(WAERK&amp;lt;&amp;gt;'EUR',&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;SUM([ZDE_UMSATZ.NETWR])+SUM(NETWR]*1.2) )&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Apr 2022 09:08:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921319#M75844</guid>
      <dc:creator>brunobertels</dc:creator>
      <dc:date>2022-04-22T09:08:55Z</dc:date>
    </item>
    <item>
      <title>Re: SUM with 2 x IF</title>
      <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921327#M75845</link>
      <description>&lt;P&gt;Hi and again, thank you.&lt;/P&gt;
&lt;P&gt;Unfortunately still an error (I can't see where though).&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Daryn_0-1650619425314.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/77670i6FA952ADBF860E1C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Daryn_0-1650619425314.png" alt="Daryn_0-1650619425314.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Apr 2022 09:23:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921327#M75845</guid>
      <dc:creator>Daryn</dc:creator>
      <dc:date>2022-04-22T09:23:52Z</dc:date>
    </item>
    <item>
      <title>Re: SUM with 2 x IF</title>
      <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921361#M75847</link>
      <description>&lt;P&gt;&lt;SPAN&gt;IF(WAERK='EUR',SUM([ZDE_UMSATZ.NETWR]) + SUM([NETWR]),IF(WAERK&amp;lt;&amp;gt;'EUR',&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;SUM([ZDE_UMSATZ.NETWR])+SUM(NETWR]*1.2) )&amp;nbsp;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt; )&amp;nbsp;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Apr 2022 10:26:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921361#M75847</guid>
      <dc:creator>brunobertels</dc:creator>
      <dc:date>2022-04-22T10:26:22Z</dc:date>
    </item>
    <item>
      <title>Re: SUM with 2 x IF</title>
      <link>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921369#M75848</link>
      <description>&lt;P&gt;Hi Bruno,&lt;/P&gt;
&lt;P&gt;Again still an error. I can't see why though!&lt;/P&gt;
&lt;P&gt;However following your guidance, I have it working with a nested IF:&lt;/P&gt;
&lt;P&gt;IF (WAERK='EUR',SUM([ZDE_UMSATZ.NETWR]) + SUM([NETWR]),&lt;BR /&gt;IF (WAERK='GBP',SUM([ZDE_UMSATZ.NETWR]*1.2) + SUM([NETWR]*1.2)&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Daryn_0-1650623596807.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/77683iEAE658BE2F90EB46/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Daryn_0-1650623596807.png" alt="Daryn_0-1650623596807.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;I can add another If for the USD.&lt;/P&gt;
&lt;P&gt;Really appreciate your replies and guidance &lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;, thank you.&amp;nbsp; Have a great weekend.&lt;/P&gt;</description>
      <pubDate>Fri, 22 Apr 2022 10:42:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SUM-with-2-x-IF/m-p/1921369#M75848</guid>
      <dc:creator>Daryn</dc:creator>
      <dc:date>2022-04-22T10:42:43Z</dc:date>
    </item>
  </channel>
</rss>

