<?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 Variable issue in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Variable-issue/m-p/177102#M503626</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have an issue with Variables&lt;/P&gt;&lt;P&gt;The following is the code to create and populate the variable in the Qlikview Editor&lt;/P&gt;&lt;P&gt;LET vFinanceYearPeriod = peek('MinFY');&lt;/P&gt;&lt;P&gt;My issue is that I must use another variable in the &lt;B&gt;"Settings"&lt;/B&gt; - "&lt;B&gt;Variables Overview"&lt;/B&gt; menu to calculate a Total figure to use in charts and gauges. This new variable call ThisMonthsInvoices will use the previously defined variable vFinanceYearPeriod above as part of its calculation&lt;/P&gt;&lt;P&gt;sum(if(FinanceYearPeriod = $(vFinanceYearPeriod),GBPAmountInvoice);&lt;/P&gt;&lt;P&gt;when I use the new variable in my charts I get the value 0.&lt;/P&gt;&lt;P&gt;In order to prove my sanity I created a temporary table to ensure that there is a matching value in the original table using the code below and it pulls the expected data.&lt;/P&gt;&lt;P&gt;Temp:&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;SELECT CustomerType,&lt;BR /&gt; GBPAmountInvoice,&lt;BR /&gt;resident Transactions&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;WHERE FinanceYearPeriod = $(vFinanceYearPeriod);&lt;/P&gt;&lt;P&gt;As you can see the selection in side the variables if statement is the same as the selection on the load statement for my temporary table but the table load will find the required values whereas the calculation insode the variable will nor find anything.&lt;/P&gt;&lt;P&gt;I would be grateful if anyone could let me know what I am doing wrong ? I am new to qlikview.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 11 Mar 2010 18:25:34 GMT</pubDate>
    <dc:creator />
    <dc:date>2010-03-11T18:25:34Z</dc:date>
    <item>
      <title>Variable issue</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-issue/m-p/177102#M503626</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have an issue with Variables&lt;/P&gt;&lt;P&gt;The following is the code to create and populate the variable in the Qlikview Editor&lt;/P&gt;&lt;P&gt;LET vFinanceYearPeriod = peek('MinFY');&lt;/P&gt;&lt;P&gt;My issue is that I must use another variable in the &lt;B&gt;"Settings"&lt;/B&gt; - "&lt;B&gt;Variables Overview"&lt;/B&gt; menu to calculate a Total figure to use in charts and gauges. This new variable call ThisMonthsInvoices will use the previously defined variable vFinanceYearPeriod above as part of its calculation&lt;/P&gt;&lt;P&gt;sum(if(FinanceYearPeriod = $(vFinanceYearPeriod),GBPAmountInvoice);&lt;/P&gt;&lt;P&gt;when I use the new variable in my charts I get the value 0.&lt;/P&gt;&lt;P&gt;In order to prove my sanity I created a temporary table to ensure that there is a matching value in the original table using the code below and it pulls the expected data.&lt;/P&gt;&lt;P&gt;Temp:&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;SELECT CustomerType,&lt;BR /&gt; GBPAmountInvoice,&lt;BR /&gt;resident Transactions&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;WHERE FinanceYearPeriod = $(vFinanceYearPeriod);&lt;/P&gt;&lt;P&gt;As you can see the selection in side the variables if statement is the same as the selection on the load statement for my temporary table but the table load will find the required values whereas the calculation insode the variable will nor find anything.&lt;/P&gt;&lt;P&gt;I would be grateful if anyone could let me know what I am doing wrong ? I am new to qlikview.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Mar 2010 18:25:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-issue/m-p/177102#M503626</guid>
      <dc:creator />
      <dc:date>2010-03-11T18:25:34Z</dc:date>
    </item>
    <item>
      <title>Variable issue</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-issue/m-p/177103#M503627</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not sure if it's related, but you are missing a closing paren at the end of your formula...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Mar 2010 22:43:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-issue/m-p/177103#M503627</guid>
      <dc:creator>Oleg_Troyansky</dc:creator>
      <dc:date>2010-03-11T22:43:38Z</dc:date>
    </item>
  </channel>
</rss>

