<?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 in where clause in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151455#M376188</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to load a table with filter in Where clause position and i need your help&lt;/P&gt;&lt;P&gt;how can i load only quarter 2016-Q3 if this is my script&lt;/P&gt;&lt;P&gt;The current "&lt;SPAN style="font-size: 13.3333px;"&gt;Quarter_Rank" is 38 and i need to load next &lt;SPAN style="font-size: 13.3333px;"&gt;Next_Quarter_Rank&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Table:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Product 1], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [&lt;SPAN style="font-size: 13.3333px;"&gt;Product 2&lt;/SPAN&gt;], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Total Qty], &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Year Quarter],&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;&amp;nbsp;&amp;nbsp;&amp;nbsp; // &lt;SPAN style="font-size: 13.3333px;"&gt;format: '&lt;/SPAN&gt;2016-Q2'&amp;nbsp; (list of quarters from 2013-Q1 to 2017-Q4) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Quarter_Rank,&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;&amp;nbsp;&amp;nbsp; // numbers 1 to 100, each quarter have a number&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next_Quarter_Rank, &lt;SPAN style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 39 (number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Actual_Quarter_Rank&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 38 (number)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;[..\QVD\Test\FC_Quarter.qvd]&lt;/P&gt;&lt;P&gt;(qvd)&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Where&amp;nbsp; Quarter_Rank = / * &lt;STRONG style="font-size: 13.3333px;"&gt;i need a variable here to load &lt;SPAN style="font-size: 13.3333px;"&gt;Quarter_Rank= &lt;/SPAN&gt;&lt;/STRONG&gt; &lt;SPAN style="color: #575757; text-decoration: underline;"&gt;39&lt;/SPAN&gt;&amp;nbsp; * / &lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&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;i tried this kind:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;Where&amp;nbsp; Next_Quarter_Rank = Actual_Quarter_Rank + 1 but doesn't work (load empty)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;can someone advise the right &lt;/SPAN&gt;method&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Daniel&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;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 20 Jun 2016 09:20:56 GMT</pubDate>
    <dc:creator>daniel_f</dc:creator>
    <dc:date>2016-06-20T09:20:56Z</dc:date>
    <item>
      <title>Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151455#M376188</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to load a table with filter in Where clause position and i need your help&lt;/P&gt;&lt;P&gt;how can i load only quarter 2016-Q3 if this is my script&lt;/P&gt;&lt;P&gt;The current "&lt;SPAN style="font-size: 13.3333px;"&gt;Quarter_Rank" is 38 and i need to load next &lt;SPAN style="font-size: 13.3333px;"&gt;Next_Quarter_Rank&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Table:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Product 1], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [&lt;SPAN style="font-size: 13.3333px;"&gt;Product 2&lt;/SPAN&gt;], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Total Qty], &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Year Quarter],&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;&amp;nbsp;&amp;nbsp;&amp;nbsp; // &lt;SPAN style="font-size: 13.3333px;"&gt;format: '&lt;/SPAN&gt;2016-Q2'&amp;nbsp; (list of quarters from 2013-Q1 to 2017-Q4) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Quarter_Rank,&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;&amp;nbsp;&amp;nbsp; // numbers 1 to 100, each quarter have a number&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next_Quarter_Rank, &lt;SPAN style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 39 (number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Actual_Quarter_Rank&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 38 (number)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;[..\QVD\Test\FC_Quarter.qvd]&lt;/P&gt;&lt;P&gt;(qvd)&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Where&amp;nbsp; Quarter_Rank = / * &lt;STRONG style="font-size: 13.3333px;"&gt;i need a variable here to load &lt;SPAN style="font-size: 13.3333px;"&gt;Quarter_Rank= &lt;/SPAN&gt;&lt;/STRONG&gt; &lt;SPAN style="color: #575757; text-decoration: underline;"&gt;39&lt;/SPAN&gt;&amp;nbsp; * / &lt;/STRONG&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&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;i tried this kind:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;Where&amp;nbsp; Next_Quarter_Rank = Actual_Quarter_Rank + 1 but doesn't work (load empty)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;can someone advise the right &lt;/SPAN&gt;method&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Daniel&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;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 09:20:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151455#M376188</guid>
      <dc:creator>daniel_f</dc:creator>
      <dc:date>2016-06-20T09:20:56Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151456#M376189</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do &lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next_Quarter_Rank, &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 13.3333px; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 39 (number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Actual_Quarter_Rank&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 38 (number)&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;show a constant value for each record in your input table?&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Then &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;EM&gt;Where&amp;nbsp; Next_Quarter_Rank = Actual_Quarter_Rank + 1;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;should return true and you should see all records. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;But that's probably also not the filter you want to achieve, right?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;Maybe&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;EM style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;Where&amp;nbsp; Quarter_Rank = Actual_Quarter_Rank + 1;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;EM style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;&lt;EM style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;?&lt;BR /&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 09:33:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151456#M376189</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2016-06-20T09:33:24Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151457#M376190</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;try below script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tmp:&lt;/P&gt;&lt;P&gt;load&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; max(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Next_Quarter_Rank)&amp;nbsp; as &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Next_Quarter_Rank&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;FROM&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;[..\QVD\Test\FC_Quarter.qvd]&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;(qvd) where &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt;[Year Quarter]='&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;2016-Q3';&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;let vQtrNum = peek('&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Next_Quarter_Rank');&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;drop table tmp;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Table:&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;LOAD&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Product 1],&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 13.3333px; font-family: inherit;"&gt;Product 2&lt;/SPAN&gt;],&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Total Qty],&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 13.3333px; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Year Quarter],&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;&amp;nbsp;&amp;nbsp;&amp;nbsp; // &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 13.3333px; font-family: inherit;"&gt;format: '&lt;/SPAN&gt;2016-Q2'&amp;nbsp; (list of quarters from 2013-Q1 to 2017-Q4)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Quarter_Rank,&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;&amp;nbsp;&amp;nbsp; // numbers 1 to 100, each quarter have a number&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next_Quarter_Rank, &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 13.3333px; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 39 (number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Actual_Quarter_Rank&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // is 38 (number)&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;FROM&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;[..\QVD\Test\FC_Quarter.qvd]&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;(qvd) where &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Quarter_Rank=$(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;vQtrNum&lt;/SPAN&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;$@M.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 09:37:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151457#M376190</guid>
      <dc:creator>mightyqlikers</dc:creator>
      <dc:date>2016-06-20T09:37:03Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151458#M376191</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi SAM,&lt;/P&gt;&lt;P&gt;thanks for your quickly respond, but the problem with this script is that is not automatically&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;"where &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;[Year Quarter]='&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 13px;"&gt;2016-Q3';" is manually&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-style: inherit; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;since i know what the actual quarter rank is, i want to create some automatically load process&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-style: inherit; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-style: inherit; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;any other idea?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-style: inherit; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;thanks&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-style: inherit; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;Daniel&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-style: inherit; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 11:26:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151458#M376191</guid>
      <dc:creator>daniel_f</dc:creator>
      <dc:date>2016-06-20T11:26:20Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151459#M376192</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Swuehl,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i need something like: where&amp;nbsp; Quarter_Rank = Next_Quarter_Rank&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;your sample 1: &lt;EM style="font-size: 13.3333px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;Where&amp;nbsp; Next_Quarter_Rank = Actual_Quarter_Rank + 1;&lt;/STRONG&gt; &lt;/EM&gt;show me the current quarter (not the next)&lt;/P&gt;&lt;P&gt;your sample 2:&lt;EM style="font-size: 13.3333px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;Where&amp;nbsp; Quarter_Rank = Actual_Quarter_Rank + 1; &lt;/STRONG&gt;&lt;/EM&gt;doesn't work&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;any other idea?&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 11:37:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151459#M376192</guid>
      <dc:creator>daniel_f</dc:creator>
      <dc:date>2016-06-20T11:37:01Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151460#M376193</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Lot of ideas, but without knowing how your input table records actually look like, it does not make sense to guess.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 13:19:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151460#M376193</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2016-06-20T13:19:58Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151461#M376194</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Daniel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you please post sample Application with Expect O/P. As Swuehl, How do we get the Correct?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 13:38:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151461#M376194</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2016-06-20T13:38:58Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151462#M376195</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Instead of the hard coded you can use something like that:&lt;/P&gt;&lt;P&gt;LET next_q = Year(AddMonths(Date(Now()),4))&amp;amp;'-Q'&amp;amp;Ceil(Month(AddMonths(Date(Now()),4))/4);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2016 14:31:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151462#M376195</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-06-20T14:31:00Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151463#M376196</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;i added the qvw in order to try to get a solution&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2016 05:55:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151463#M376196</guid>
      <dc:creator>daniel_f</dc:creator>
      <dc:date>2016-06-22T05:55:29Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151464#M376197</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This may be helpful while uploading the data from QVD..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;where YearQuarter = year(Date(now()))&amp;amp;'-Q'&amp;amp;(Ceil(Num(Month(Date(now())))/3)+1)..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am assuming each quarter has only one rank. This script will upload the data for next quarter ..but this has a limitation on when you are reloading the script.. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now it shows 2016-Q3 data as the we are in Jun(Q2)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2016 07:03:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151464#M376197</guid>
      <dc:creator>narayanamsn</dc:creator>
      <dc:date>2016-06-22T07:03:31Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151465#M376198</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can this file help?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2016 08:34:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151465#M376198</guid>
      <dc:creator>daniel_f</dc:creator>
      <dc:date>2016-06-22T08:34:22Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151466#M376199</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Satya,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;thank for your help&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;You assuming right, each quarter have only one rank.&lt;/P&gt;&lt;P&gt;well, the script is working but i don't understand what the &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;limitation &lt;/SPAN&gt;is when i reload the script.&lt;/P&gt;&lt;P&gt;additional, the formula is not generic. for example "&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;year(Date(now()))" will not be valid when i'll be on &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;2016-&lt;/SPAN&gt;Q4&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;any other idea&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2016 08:50:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151466#M376199</guid>
      <dc:creator>daniel_f</dc:creator>
      <dc:date>2016-06-22T08:50:17Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151467#M376200</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Daniel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How about Dense_Rank() in DB?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2016 09:40:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151467#M376200</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2016-06-22T09:40:58Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151468#M376201</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;My calculation is generic:&lt;/P&gt;&lt;P&gt;I tried it with the following two dates and it worked perfectly giving 2017-Q1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET YearQuarter_1 = Year(AddMonths(Date('10/01/2016'),4))&amp;amp;'-Q'&amp;amp;Ceil(Month(AddMonths(Date('10/01/2016'),4))/4);&lt;/P&gt;&lt;P&gt;LET YearQuarter_2 = Year(AddMonths(Date('12/31/2016'),4))&amp;amp;'-Q'&amp;amp;Ceil(Month(AddMonths(Date('12/31/2016'),4))/4);&lt;/P&gt;&lt;P&gt;trace $(YearQuarter_1)&amp;nbsp;&amp;nbsp; $(YearQuarter_2);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2016 09:46:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151468#M376201</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-06-22T09:46:34Z</dc:date>
    </item>
    <item>
      <title>Re: Variable in where clause</title>
      <link>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151469#M376202</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can you please explain?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2016 11:09:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Variable-in-where-clause/m-p/1151469#M376202</guid>
      <dc:creator>daniel_f</dc:creator>
      <dc:date>2016-06-22T11:09:09Z</dc:date>
    </item>
  </channel>
</rss>

