<?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: Problem creating a Variable from Load Script in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Problem-creating-a-Variable-from-Load-Script/m-p/59252#M605553</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Once you reload the app, you can either create an input box object and add the variable vLastQtr or press Ctrl + Alt + v and see the content of the variable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also add in your script a TRACE function to display in the loading screen the value of the variable:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let vLastQtr = Num(Peek('[MaxQtr]',1));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TRACE --&amp;gt; $(vLastQtr);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Drop Table LastQtrNR;&lt;/P&gt;&lt;P&gt;[...]&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 05 Jun 2018 15:09:00 GMT</pubDate>
    <dc:creator>Miguel_Angel_Baeyens</dc:creator>
    <dc:date>2018-06-05T15:09:00Z</dc:date>
    <item>
      <title>Problem creating a Variable from Load Script</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-creating-a-Variable-from-Load-Script/m-p/59251#M605552</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;He Everyone&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; I'm new to QlikView and I am struggling with variables, I've the following Script&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="357" style="border: 1px solid rgb(0, 0, 0); width: 714px; height: 359px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: rgb(102, 144, 188); color: rgb(255, 255, 255); padding: 2px;" valign="middle"&gt;&lt;SPAN style="color: #575757; font-size: 13.3333px;"&gt;Script&lt;/SPAN&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px; text-align: left;"&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;LastQtrNR:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Load &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Max(Num(Mid(Trim([Period]),3,2))+ (Num(Right(Trim([Period]),1))/10))) As [MaxQtr]&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;From [..\QlikView\DataSource.qvd](qvd)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Where [Metric] &amp;lt;&amp;gt; 0&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Let vLastQtr = Num(Peek('[MaxQtr]',1));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Drop Table LastQtrNR;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;T:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Load '$(vLastQtr)' As MaxQuarter;&lt;/SPAN&gt;&lt;/P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thing is the result of the first load statement should be "18.1" Which I will convert in FY18 Q1, and store it in vLastQtr, however, I'm not able to verify the result of the variable assignation with the load, and I'm not sure on how to modify the variable value to use it as a filter for other queries&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jun 2018 14:16:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-creating-a-Variable-from-Load-Script/m-p/59251#M605552</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-06-05T14:16:17Z</dc:date>
    </item>
    <item>
      <title>Re: Problem creating a Variable from Load Script</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-creating-a-Variable-from-Load-Script/m-p/59252#M605553</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Once you reload the app, you can either create an input box object and add the variable vLastQtr or press Ctrl + Alt + v and see the content of the variable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also add in your script a TRACE function to display in the loading screen the value of the variable:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let vLastQtr = Num(Peek('[MaxQtr]',1));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TRACE --&amp;gt; $(vLastQtr);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Drop Table LastQtrNR;&lt;/P&gt;&lt;P&gt;[...]&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jun 2018 15:09:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-creating-a-Variable-from-Load-Script/m-p/59252#M605553</guid>
      <dc:creator>Miguel_Angel_Baeyens</dc:creator>
      <dc:date>2018-06-05T15:09:00Z</dc:date>
    </item>
  </channel>
</rss>

