<?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: where clause in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/where-clause/m-p/770604#M1046287</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you post the entire script&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 19 Nov 2014 05:14:15 GMT</pubDate>
    <dc:creator>anbu1984</dc:creator>
    <dc:date>2014-11-19T05:14:15Z</dc:date>
    <item>
      <title>where clause</title>
      <link>https://community.qlik.com/t5/QlikView/where-clause/m-p/770600#M1046283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;I am trying to load values where a year is matching, but instead of loading values where a year is matching, the code is assigning the year value of one to another and thus loading everything.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the code I am using is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[ExistingMonths]:&lt;/P&gt;&lt;P&gt;&amp;nbsp; LOAD DISTINCT&lt;/P&gt;&lt;P&gt;&amp;nbsp; [Month]&lt;/P&gt;&lt;P&gt;&amp;nbsp; FROM&lt;/P&gt;&lt;P&gt;&amp;nbsp; [ExistingMonths.qvd]&lt;/P&gt;&lt;P&gt;&amp;nbsp; (qvd)&lt;/P&gt;&lt;P&gt;&amp;nbsp; WHERE&lt;/P&gt;&lt;P&gt;&amp;nbsp; [Month] = '$(vNewMonth)';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; LET vMonth = PEEK('Month',0);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The vNewMonth variable is taking value from the source file, which is correct.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Before the where statement values are different, but after the where statement, [Month] field takes the value of vNewMonth variable and hence the vMonth variable as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Nov 2014 13:29:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/where-clause/m-p/770600#M1046283</guid>
      <dc:creator />
      <dc:date>2014-11-18T13:29:04Z</dc:date>
    </item>
    <item>
      <title>Re: where clause</title>
      <link>https://community.qlik.com/t5/QlikView/where-clause/m-p/770601#M1046284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Y B&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am not sure what you expect to get...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is obvious that if you LOAD [Month] from a qvd and have a WHERE clause stating that [Month] = '$(vNewMonth)'&lt;/P&gt;&lt;P&gt;the [Month] field can only have the same value as vNewMonth. (Or the table will be empty if no matching [Month] is found in the qvd.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/gg&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Nov 2014 13:46:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/where-clause/m-p/770601#M1046284</guid>
      <dc:creator>gandalfgray</dc:creator>
      <dc:date>2014-11-18T13:46:01Z</dc:date>
    </item>
    <item>
      <title>Re: where clause</title>
      <link>https://community.qlik.com/t5/QlikView/where-clause/m-p/770602#M1046285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can u come up with clear explination ,&lt;/P&gt;&lt;P&gt;there is lot of confusion&lt;/P&gt;&lt;P&gt;what is the value of&amp;nbsp;&amp;nbsp;&amp;nbsp; vnewmonth?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Nov 2014 13:50:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/where-clause/m-p/770602#M1046285</guid>
      <dc:creator />
      <dc:date>2014-11-18T13:50:36Z</dc:date>
    </item>
    <item>
      <title>Re: where clause</title>
      <link>https://community.qlik.com/t5/QlikView/where-clause/m-p/770603#M1046286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;no, but my source file doesn't have that month. So I am expecting no rows and hence vMonth = ' ' (Null value).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, the where clause is assigning the new month values to existing ones and loading everything.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Even I am confused.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Nov 2014 05:08:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/where-clause/m-p/770603#M1046286</guid>
      <dc:creator />
      <dc:date>2014-11-19T05:08:00Z</dc:date>
    </item>
    <item>
      <title>Re: where clause</title>
      <link>https://community.qlik.com/t5/QlikView/where-clause/m-p/770604#M1046287</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you post the entire script&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Nov 2014 05:14:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/where-clause/m-p/770604#M1046287</guid>
      <dc:creator>anbu1984</dc:creator>
      <dc:date>2014-11-19T05:14:15Z</dc:date>
    </item>
  </channel>
</rss>

