<?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: Evaluate dynamic variables within a variable in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Evaluate-dynamic-variables-within-a-variable/m-p/1549833#M440162</link>
    <description>&lt;P&gt;The way parameterized variables are invoked is not correct, please check the link&amp;nbsp;&lt;A href="https://community.qlik.com/t5/QlikView-Documents/Qlikview-Parameterised-Variables/ta-p/1494184" target="_blank"&gt;https://community.qlik.com/t5/QlikView-Documents/Qlikview-Parameterised-Variables/ta-p/1494184&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 27 Feb 2019 12:48:29 GMT</pubDate>
    <dc:creator>anushree1</dc:creator>
    <dc:date>2019-02-27T12:48:29Z</dc:date>
    <item>
      <title>Evaluate dynamic variables within a variable</title>
      <link>https://community.qlik.com/t5/QlikView/Evaluate-dynamic-variables-within-a-variable/m-p/1549718#M440156</link>
      <description>&lt;P&gt;Dear all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I do have an app, where I reuse expression for a lot of tables, so I created variables to store these, for example a variable vKL_KPI_GEN_ACYTD that calculates the sum of the actuals and&amp;nbsp;vKL_KPI_GEN_BUYTD that calculates the sum of the budget figures and so on.&lt;/P&gt;&lt;P&gt;Now I have to compare the figures dynamically and assign them colors for good and bad, for example actuals vs. budget, actuals vs. forecast and so on. So I created another parametrized variable, which is defined as:&lt;/P&gt;&lt;P&gt;IF( $( $2 ) &amp;gt;= 0,&lt;BR /&gt;IF( $( $1 ) &amp;gt;= PICK(ZZZHIGHISGOOD, ZZZLIMIT_GOOD, (2-ZZZLIMIT_GOOD)) * $( $2 ) ,&lt;BR /&gt;PICK(ZZZHIGHISGOOD, vC_Figure_Good, vC_Figure_Bad),&lt;BR /&gt;IF( $( $1 ) &amp;lt; PICK(ZZZHIGHISGOOD, ZZZLIMIT_BAD, (2-ZZZLIMIT_BAD)) * $( $2 ), PICK(ZZZHIGHISGOOD, vC_Figure_Bad, vC_Figure_Good), vC_Figure_Neutral)),&lt;BR /&gt;IF( $( $1 ) &amp;gt;= PICK(ZZZHIGHISGOOD, (2-ZZZLIMIT_GOOD), ZZZLIMIT_GOOD) * $( $2 ),&lt;BR /&gt;PICK(ZZZHIGHISGOOD, vC_Figure_Good, vC_Figure_Bad),&lt;BR /&gt;IF( $( $1 ) &amp;lt; PICK(ZZZHIGHISGOOD, (2-ZZZLIMIT_BAD), ZZZLIMIT_BAD) * $( $2 ), PICK(ZZZHIGHISGOOD, vC_Figure_Bad, vC_Figure_Good), vC_Figure_Neutral))&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;and is called in diagrams and tables via&lt;/P&gt;&lt;P&gt;$(vI_EVALCOLOR( 'vKL_KPI_GEN_ACYTD', 'vKL_KPI_GEN_BUYTD'))&lt;/P&gt;&lt;P&gt;This does not work however. If I do not use the variable but write&lt;/P&gt;&lt;P&gt;IF( $(vKL_KPI_GEN_BUYTD) &amp;gt;= 0,&lt;BR /&gt;IF( $(vKL_KPI_GEN_ACYTD) &amp;gt;= PICK(ZZZHIGHISGOOD, ZZZLIMIT_GOOD, (2-ZZZLIMIT_GOOD)) * $(vKL_KPI_GEN_BUYTD) ,&lt;BR /&gt;PICK(ZZZHIGHISGOOD, vC_Figure_Good, vC_Figure_Bad),&lt;BR /&gt;IF( $(vKL_KPI_GEN_ACYTD) &amp;lt; PICK(ZZZHIGHISGOOD, ZZZLIMIT_BAD, (2-ZZZLIMIT_BAD)) * $(vKL_KPI_GEN_BUYTD), PICK(ZZZHIGHISGOOD, vC_Figure_Bad, vC_Figure_Good), vC_Figure_Neutral)),&lt;BR /&gt;IF( $(vKL_KPI_GEN_ACYTD) &amp;gt;= PICK(ZZZHIGHISGOOD, (2-ZZZLIMIT_GOOD), ZZZLIMIT_GOOD) * $(vKL_KPI_GEN_BUYTD),&lt;BR /&gt;PICK(ZZZHIGHISGOOD, vC_Figure_Good, vC_Figure_Bad),&lt;BR /&gt;IF( $(vKL_KPI_GEN_ACYTD) &amp;lt; PICK(ZZZHIGHISGOOD, (2-ZZZLIMIT_BAD), ZZZLIMIT_BAD) * $(vKL_KPI_GEN_BUYTD), PICK(ZZZHIGHISGOOD, vC_Figure_Bad, vC_Figure_Good), vC_Figure_Neutral))&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;in the table it works fine.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any ideas anyone?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Roman&lt;/P&gt;</description>
      <pubDate>Wed, 27 Feb 2019 10:08:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Evaluate-dynamic-variables-within-a-variable/m-p/1549718#M440156</guid>
      <dc:creator>roman_blaser</dc:creator>
      <dc:date>2019-02-27T10:08:43Z</dc:date>
    </item>
    <item>
      <title>Re: Evaluate dynamic variables within a variable</title>
      <link>https://community.qlik.com/t5/QlikView/Evaluate-dynamic-variables-within-a-variable/m-p/1549833#M440162</link>
      <description>&lt;P&gt;The way parameterized variables are invoked is not correct, please check the link&amp;nbsp;&lt;A href="https://community.qlik.com/t5/QlikView-Documents/Qlikview-Parameterised-Variables/ta-p/1494184" target="_blank"&gt;https://community.qlik.com/t5/QlikView-Documents/Qlikview-Parameterised-Variables/ta-p/1494184&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 27 Feb 2019 12:48:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Evaluate-dynamic-variables-within-a-variable/m-p/1549833#M440162</guid>
      <dc:creator>anushree1</dc:creator>
      <dc:date>2019-02-27T12:48:29Z</dc:date>
    </item>
  </channel>
</rss>

