<?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 Two set analysis expressions in one expression in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Two-set-analysis-expressions-in-one-expression/m-p/1201989#M627143</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;I am trying to implement the below logic into an expression in a pivot table. For one subset of my data I'd like to sum&amp;nbsp; the "Current Balance" field for a different "Production Date" than the other set. The problem is that they do not sum together in the end. Is there anything that I can add to the logic that would allow these to add together in the pivot table?Is an if statement the way to go for this or is there a better way?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;if([Toggle]= 'Yes'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;, sum({$&amp;lt;[Production Date]={"=2016-04-29"}&amp;gt;} [Current Balance]/1000)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;, sum({$&amp;lt;[Production Date]={"$(=date(max({1&amp;lt;Year={$(=max(Year)-1)}&amp;gt;} [Production Date])))"}&amp;gt;} [Current Balance] /1000), )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;Thank you.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 31 Oct 2016 17:24:56 GMT</pubDate>
    <dc:creator />
    <dc:date>2016-10-31T17:24:56Z</dc:date>
    <item>
      <title>Two set analysis expressions in one expression</title>
      <link>https://community.qlik.com/t5/QlikView/Two-set-analysis-expressions-in-one-expression/m-p/1201989#M627143</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;I am trying to implement the below logic into an expression in a pivot table. For one subset of my data I'd like to sum&amp;nbsp; the "Current Balance" field for a different "Production Date" than the other set. The problem is that they do not sum together in the end. Is there anything that I can add to the logic that would allow these to add together in the pivot table?Is an if statement the way to go for this or is there a better way?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;if([Toggle]= 'Yes'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;, sum({$&amp;lt;[Production Date]={"=2016-04-29"}&amp;gt;} [Current Balance]/1000)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;, sum({$&amp;lt;[Production Date]={"$(=date(max({1&amp;lt;Year={$(=max(Year)-1)}&amp;gt;} [Production Date])))"}&amp;gt;} [Current Balance] /1000), )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;Thank you.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Oct 2016 17:24:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Two-set-analysis-expressions-in-one-expression/m-p/1201989#M627143</guid>
      <dc:creator />
      <dc:date>2016-10-31T17:24:56Z</dc:date>
    </item>
  </channel>
</rss>

