<?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 Nested IF statement as a variable in the Script in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Nested-IF-statement-as-a-variable-in-the-Script/m-p/1123572#M19482</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;STRONG style="text-decoration: underline;"&gt;Question:&lt;/STRONG&gt; How are the below variables written in the &lt;STRONG&gt;script&lt;/STRONG&gt;? The Qlik Sense application sits on the SERVER, hence the requirement for&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; SCRIPT VARIABLES.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;STRONG&gt;vUserProductGroup&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;concat(Distinct Site_Master_Person_Product_Group)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="line-height: 1.5em; font-size: 13.3333px;"&gt;&lt;STRONG&gt;vProductDivision&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;=&lt;/SPAN&gt;if($(vUserProductGroup) = 'MOBILE','IM',&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt; if($(vUserProductGroup) = 'TV','TVAV'))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;This is the KPI expression:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;*************************************************************************************************&lt;/P&gt;&lt;P&gt;if(vProductDivision = 'IM',&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;(sum({&amp;lt;[Product PREMIUM] = {'Premium'},[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;/&lt;/P&gt;&lt;P&gt;sum({&amp;lt;[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty)),&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;if(vProductDivision = 'TVAV',&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(sum({&amp;lt;[Product PREMIUM] = {'PREMIUM'},[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty)&lt;/P&gt;&lt;P&gt;/&lt;/P&gt;&lt;P&gt;sum({&amp;lt;[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty))))&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;*************************************************************************************************&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 22 Jul 2016 09:29:52 GMT</pubDate>
    <dc:creator />
    <dc:date>2016-07-22T09:29:52Z</dc:date>
    <item>
      <title>Nested IF statement as a variable in the Script</title>
      <link>https://community.qlik.com/t5/App-Development/Nested-IF-statement-as-a-variable-in-the-Script/m-p/1123572#M19482</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;STRONG style="text-decoration: underline;"&gt;Question:&lt;/STRONG&gt; How are the below variables written in the &lt;STRONG&gt;script&lt;/STRONG&gt;? The Qlik Sense application sits on the SERVER, hence the requirement for&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; SCRIPT VARIABLES.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;STRONG&gt;vUserProductGroup&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;concat(Distinct Site_Master_Person_Product_Group)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="line-height: 1.5em; font-size: 13.3333px;"&gt;&lt;STRONG&gt;vProductDivision&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;=&lt;/SPAN&gt;if($(vUserProductGroup) = 'MOBILE','IM',&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt; if($(vUserProductGroup) = 'TV','TVAV'))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;This is the KPI expression:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;*************************************************************************************************&lt;/P&gt;&lt;P&gt;if(vProductDivision = 'IM',&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;(sum({&amp;lt;[Product PREMIUM] = {'Premium'},[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;/&lt;/P&gt;&lt;P&gt;sum({&amp;lt;[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty)),&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;if(vProductDivision = 'TVAV',&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(sum({&amp;lt;[Product PREMIUM] = {'PREMIUM'},[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty)&lt;/P&gt;&lt;P&gt;/&lt;/P&gt;&lt;P&gt;sum({&amp;lt;[Product RM Division] = {$(vProductDivision)}&amp;gt;}Sell_Out_Qty))))&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;*************************************************************************************************&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Jul 2016 09:29:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Nested-IF-statement-as-a-variable-in-the-Script/m-p/1123572#M19482</guid>
      <dc:creator />
      <dc:date>2016-07-22T09:29:52Z</dc:date>
    </item>
    <item>
      <title>Re: Nested IF statement as a variable in the Script</title>
      <link>https://community.qlik.com/t5/App-Development/Nested-IF-statement-as-a-variable-in-the-Script/m-p/1123573#M19483</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be look at Stefan's response here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/message/1062225"&gt;Re: Expression as a variable with $-sign expansion&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Jul 2016 11:23:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Nested-IF-statement-as-a-variable-in-the-Script/m-p/1123573#M19483</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-07-22T11:23:41Z</dc:date>
    </item>
  </channel>
</rss>

