<?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: Expression Total using If and Else condition in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91608#M755826</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, it worked... I chose to go with option two and it gave me the results I wanted. Thanks Oiliver!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Sep 2018 13:03:53 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-09-21T13:03:53Z</dc:date>
    <item>
      <title>Expression Total using If and Else condition</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91603#M755821</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have been tasked to amend the Qlikview pivot table where I need to put an If and Else condition on the expression where it says if Name = 'ABC' than do calculation this way else the other way. The expression with If and Else is working fine at row level is calculation basis the names however the total shown is ignoring the If and Else and considering only the else part. Example given below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Name&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CalculatedField&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10&lt;/P&gt;&lt;P&gt;BC&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10&lt;/P&gt;&lt;P&gt;ABC&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Total&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ideally the total should be 25 as one of the row has ABC name but instead the total is ignoring If part which will consider 5 but taking this into Else part which is considering 10.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help will be appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot in advance!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91603#M755821</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Expression Total using If and Else condition</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91604#M755822</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;maybe you have used total of expression option for your expression,&lt;/P&gt;&lt;P&gt;and with if(xxxxxx) it can't work&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check option : sum of rows&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Sep 2018 13:02:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91604#M755822</guid>
      <dc:creator>ogautier62</dc:creator>
      <dc:date>2018-09-20T13:02:34Z</dc:date>
    </item>
    <item>
      <title>Re: Expression Total using If and Else condition</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91605#M755823</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Olivier Gautier, Thanks you are right by changing it to Sum of rows this worked.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Sep 2018 13:46:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91605#M755823</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-09-20T13:46:55Z</dc:date>
    </item>
    <item>
      <title>Re: Expression Total using If and Else condition</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91606#M755824</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Any idea how this can be achieved when only giving one row with totals? If changed to sum of rows it gives 0 as there is no row to do sum on.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Sep 2018 14:16:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91606#M755824</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-09-20T14:16:15Z</dc:date>
    </item>
    <item>
      <title>Re: Expression Total using If and Else condition</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91607#M755825</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;in this case you have to use an expression beginning with an aggregator, and not begin with if&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so replace if( abc, sum(this way), sum(that way)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;by :&lt;/P&gt;&lt;P&gt;sum(if(abc, this way, that way)) if it possible&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or make two columns (not visible)&lt;/P&gt;&lt;P&gt;with sum({&amp;lt;Name = {ABC} &amp;gt;}&amp;nbsp;&amp;nbsp;&amp;nbsp; this way)&lt;/P&gt;&lt;P&gt;id for the other&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and a total column = col1 + col2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so you can use total of expression&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Sep 2018 15:06:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91607#M755825</guid>
      <dc:creator>ogautier62</dc:creator>
      <dc:date>2018-09-20T15:06:57Z</dc:date>
    </item>
    <item>
      <title>Re: Expression Total using If and Else condition</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91608#M755826</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, it worked... I chose to go with option two and it gave me the results I wanted. Thanks Oiliver!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2018 13:03:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Total-using-If-and-Else-condition/m-p/91608#M755826</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-09-21T13:03:53Z</dc:date>
    </item>
  </channel>
</rss>

