<?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 If in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1620775#M733954</link>
    <description>&lt;P&gt;Try this in your expression:&lt;/P&gt;&lt;P&gt;if(&lt;BR /&gt;sum({&amp;lt;Account*={'201110','507200'}&amp;gt;}Value)=0,&lt;BR /&gt;sum({&amp;lt;Account*={'121100','122100'}&amp;gt;}Value),&lt;BR /&gt;if(sum({&amp;lt;Account*={'121100','122100','507200'}&amp;gt;}Value)&amp;lt;&amp;gt;0,&lt;BR /&gt;sum({&amp;lt;Account={'201110'}&amp;gt;}Value)*-1,0&lt;BR /&gt;))&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="clipboard_image_1.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/18568i1BA499E4C3C00619/image-size/medium?v=v2&amp;amp;px=400" role="button" title="clipboard_image_1.png" alt="clipboard_image_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Refer qvw attached for reference.&lt;/P&gt;&lt;P&gt;Thanks and regards,&lt;/P&gt;&lt;P&gt;Arthur Fong&lt;/P&gt;</description>
    <pubDate>Fri, 06 Sep 2019 00:51:43 GMT</pubDate>
    <dc:creator>Arthur_Fong</dc:creator>
    <dc:date>2019-09-06T00:51:43Z</dc:date>
    <item>
      <title>Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1620608#M733953</link>
      <description>&lt;P&gt;I have attached excel example.&amp;nbsp; I am trying to get a sumif function in set analysis to sum $amount for acct #&amp;nbsp;'=IF((+G2+H2)=0,(E2+F2),IF((E2+F2+H2)&amp;lt;&amp;gt;0,-G2,0))&lt;/P&gt;&lt;P&gt;Can someone help on the formula I need?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Josh&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="clipboard_image_0.png" style="width: 1744px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/18544i16FC192E64C515B7/image-dimensions/1744x119?v=v2" width="1744" height="119" role="button" title="clipboard_image_0.png" alt="clipboard_image_0.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1620608#M733953</guid>
      <dc:creator>jmcdermott</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1620775#M733954</link>
      <description>&lt;P&gt;Try this in your expression:&lt;/P&gt;&lt;P&gt;if(&lt;BR /&gt;sum({&amp;lt;Account*={'201110','507200'}&amp;gt;}Value)=0,&lt;BR /&gt;sum({&amp;lt;Account*={'121100','122100'}&amp;gt;}Value),&lt;BR /&gt;if(sum({&amp;lt;Account*={'121100','122100','507200'}&amp;gt;}Value)&amp;lt;&amp;gt;0,&lt;BR /&gt;sum({&amp;lt;Account={'201110'}&amp;gt;}Value)*-1,0&lt;BR /&gt;))&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="clipboard_image_1.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/18568i1BA499E4C3C00619/image-size/medium?v=v2&amp;amp;px=400" role="button" title="clipboard_image_1.png" alt="clipboard_image_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Refer qvw attached for reference.&lt;/P&gt;&lt;P&gt;Thanks and regards,&lt;/P&gt;&lt;P&gt;Arthur Fong&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 00:51:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1620775#M733954</guid>
      <dc:creator>Arthur_Fong</dc:creator>
      <dc:date>2019-09-06T00:51:43Z</dc:date>
    </item>
    <item>
      <title>Re: Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1625707#M733955</link>
      <description>&lt;P&gt;Josh, did Arthur's post/example get you what you needed?&amp;nbsp; If so, please use the Accept as Solution button on his post to give him credit for the help and to let others know his example worked for your issue.&amp;nbsp; If you are still trying to figure things out, please provide an update and any further information you can share.&lt;/P&gt;
&lt;P&gt;Regards,&lt;BR /&gt;Brett&lt;/P&gt;</description>
      <pubDate>Thu, 19 Sep 2019 12:19:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1625707#M733955</guid>
      <dc:creator>Brett_Bleess</dc:creator>
      <dc:date>2019-09-19T12:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1628196#M733956</link>
      <description>&lt;P&gt;My 3 month data set is 86k records, Arthur's formula is only working for me if if I keep the detail and do a pivot in excel. If I collapse the records to affiliate code level like I want then the numbers aren't correct.&amp;nbsp; Not sure how to fix that?&lt;/P&gt;</description>
      <pubDate>Wed, 25 Sep 2019 15:06:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1628196#M733956</guid>
      <dc:creator>jmcdermott</dc:creator>
      <dc:date>2019-09-25T15:06:43Z</dc:date>
    </item>
    <item>
      <title>Re: Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1628325#M733957</link>
      <description>&lt;P&gt;Josh, would you be able to attach your app for Arthur?&amp;nbsp; That is likely what he would need at this point in order to try to help you get things the rest of the way is my hunch, so if you can, let us know, may not need the entire thing, just a subset of data etc. in order to be able to see the data model properly and the chart and expressions etc.&amp;nbsp; Sorry I am not more help on this one.&lt;/P&gt;
&lt;P&gt;Regards,&lt;BR /&gt;Brett&lt;/P&gt;</description>
      <pubDate>Wed, 25 Sep 2019 21:17:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1628325#M733957</guid>
      <dc:creator>Brett_Bleess</dc:creator>
      <dc:date>2019-09-25T21:17:00Z</dc:date>
    </item>
    <item>
      <title>Re: Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1631225#M733958</link>
      <description>&lt;P&gt;Good afternoon Arthur,&lt;/P&gt;&lt;P&gt;I tried adding one more account to the equation and am getting a "Error in the set modifier as hoc element list" message.&amp;nbsp;&lt;/P&gt;&lt;P&gt;if(sum({&amp;lt;acct*={'201110','507200'}&amp;gt;}dom_amount)=0,&lt;BR /&gt;sum({&amp;lt;acct*={'121100','122100',}&amp;gt;}dom_amount),&lt;BR /&gt;if(sum({&amp;lt;acct*={'121100','122100','507200'}&amp;gt;}dom_amount)&amp;lt;&amp;gt;0,&lt;BR /&gt;sum({&amp;lt;acct={'201110'}&amp;gt;}dom_amount)*-1,&lt;BR /&gt;if(sum({&amp;lt;acct={'201150'}&amp;gt;}dom_amount)&amp;lt;&amp;gt;0,&lt;BR /&gt;sum({&amp;lt;acct={'201150'}&amp;gt;}dom_amount)*-1,0&lt;BR /&gt;)))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do you see the issue, or is it we can only have 2 if(sum)'s in the equation and not 3?&lt;/P&gt;</description>
      <pubDate>Thu, 03 Oct 2019 17:50:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1631225#M733958</guid>
      <dc:creator>jmcdermott</dc:creator>
      <dc:date>2019-10-03T17:50:21Z</dc:date>
    </item>
    <item>
      <title>Re: Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1631237#M733959</link>
      <description>&lt;P&gt;Josh, apologies, but I am wondering if you by chance had a look at the Help at all, it is pretty robust on Set Analysis, and I am going to include another Design Blog post as well, but if&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/6678"&gt;@Arthur_Fong&lt;/a&gt;&amp;nbsp; Arthur has a chance too to have a look, that would be great, but I wanted to try to give you something that might help here.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/ChartFunctions/SetAnalysis/set-analysis-expressions.htm" target="_blank"&gt;https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/ChartFunctions/SetAnalysis/set-analysis-expressions.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Note, there are some sublinks under the above link too, that may be where the info you truly want is located....&lt;/P&gt;
&lt;P&gt;Here is the Design Blog link, and there are some associated links at the bottom of the post, just FYI, hopefully one of these may help you find things too, I am terrible at Set Analysis unfortunately.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.qlik.com/t5/Qlik-Design-Blog/A-Primer-on-Set-Analysis/ba-p/1468344" target="_blank"&gt;https://community.qlik.com/t5/Qlik-Design-Blog/A-Primer-on-Set-Analysis/ba-p/1468344&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Regards,&lt;BR /&gt;Brett&lt;/P&gt;</description>
      <pubDate>Thu, 03 Oct 2019 18:31:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1631237#M733959</guid>
      <dc:creator>Brett_Bleess</dc:creator>
      <dc:date>2019-10-03T18:31:42Z</dc:date>
    </item>
    <item>
      <title>Re: Sum If</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1631305#M733960</link>
      <description>&lt;P&gt;The error occurs because there is an extra ',' in your expression(second line in bold):&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;if(sum({&amp;lt;acct*={'201110','507200'}&amp;gt;}dom_amount)=0,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;sum({&amp;lt;acct*={'121100','122100'&lt;U&gt;&lt;EM&gt;&lt;STRONG&gt;,&lt;/STRONG&gt;&lt;/EM&gt;&lt;/U&gt;}&amp;gt;}dom_amount),&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if(sum({&amp;lt;acct*={'121100','122100','507200'}&amp;gt;}dom_amount)&amp;lt;&amp;gt;0,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;sum({&amp;lt;acct={'201110'}&amp;gt;}dom_amount)*-1,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if(sum({&amp;lt;acct={'201150'}&amp;gt;}dom_amount)&amp;lt;&amp;gt;0,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;sum({&amp;lt;acct={'201150'}&amp;gt;}dom_amount)*-1,0&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;)))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Remove that ',' and it should work.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Thanks and regards,&lt;/P&gt;&lt;P&gt;Arthur Fong&lt;/P&gt;</description>
      <pubDate>Fri, 04 Oct 2019 01:59:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-If/m-p/1631305#M733960</guid>
      <dc:creator>Arthur_Fong</dc:creator>
      <dc:date>2019-10-04T01:59:21Z</dc:date>
    </item>
  </channel>
</rss>

