<?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 EXISTS() agony in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/EXISTS-agony/m-p/445610#M166238</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 having a really annoying problem with the EXISTS() statement, and I’m going round the bend. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here’s the set up: &lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;The database I’m working with has somewhere in the neighborhood of 3 million records. The majority of them have no related records in the database, and as a result, I don’t want them clogging up my dashboard. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I’m loading a number of other related objects first in order to create the list of users that I do want in the dashboard, all sharing a field which has been aliased (using the AS keyword) to &lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;[Member ID].&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the table I’m loading from, the member ID is called V_ID, and I’m doing this: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; Courier New&amp;amp;quot: ; color: blue; font-size: 9pt; font-family: &amp;amp;quot;"&gt;LOAD&lt;/STRONG&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt; &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;V_ID&lt;/SPAN&gt; &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;as&lt;/SPAN&gt; &lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;[Member ID]&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;,&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;…&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And, at the end of my load statement, I’m attempting to use EXISTS, and it keeps telling me the field doesn’t exist. I’ve tried: &lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;WHERE&lt;/SPAN&gt; &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;EXISTS&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;V_ID&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;[Member ID]&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;); &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;WHERE&lt;/SPAN&gt; &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;EXISTS&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;V_ID&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;“Member ID”&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;); &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;These two give me ‘Field &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;Member ID&amp;gt;&lt;/SPAN&gt; &lt;SPAN style="color: black;"&gt;does not exist’ errors. &lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;I’ve tried a few other more random things that don’t warrant description, to no avail. &lt;/SPAN&gt;&lt;SPAN style="color: black;"&gt;And the field name has been copied and pasted from the alias in previous tables, so it's not a spelling issue. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;It seems like a pretty straight forward thing to do, but it’s not working. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;I've also tried scouring the forums, and I see lots of other posts, and people gleefully using exists() in this way, but it doesn't seem to work for me.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;Help?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 23 Oct 2012 18:14:27 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-10-23T18:14:27Z</dc:date>
    <item>
      <title>EXISTS() agony</title>
      <link>https://community.qlik.com/t5/QlikView/EXISTS-agony/m-p/445610#M166238</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 having a really annoying problem with the EXISTS() statement, and I’m going round the bend. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here’s the set up: &lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;The database I’m working with has somewhere in the neighborhood of 3 million records. The majority of them have no related records in the database, and as a result, I don’t want them clogging up my dashboard. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I’m loading a number of other related objects first in order to create the list of users that I do want in the dashboard, all sharing a field which has been aliased (using the AS keyword) to &lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;[Member ID].&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the table I’m loading from, the member ID is called V_ID, and I’m doing this: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; Courier New&amp;amp;quot: ; color: blue; font-size: 9pt; font-family: &amp;amp;quot;"&gt;LOAD&lt;/STRONG&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt; &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;V_ID&lt;/SPAN&gt; &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;as&lt;/SPAN&gt; &lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;[Member ID]&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;,&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;…&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And, at the end of my load statement, I’m attempting to use EXISTS, and it keeps telling me the field doesn’t exist. I’ve tried: &lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;WHERE&lt;/SPAN&gt; &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;EXISTS&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;V_ID&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;[Member ID]&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;); &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;WHERE&lt;/SPAN&gt; &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;EXISTS&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;V_ID&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;“Member ID”&lt;/SPAN&gt;&lt;SPAN style="color: black; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;); &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;These two give me ‘Field &lt;SPAN style="color: blue; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: maroon; font-family: &amp;amp;quot;Courier New&amp;amp;quot;; font-size: 9pt;"&gt;Member ID&amp;gt;&lt;/SPAN&gt; &lt;SPAN style="color: black;"&gt;does not exist’ errors. &lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;I’ve tried a few other more random things that don’t warrant description, to no avail. &lt;/SPAN&gt;&lt;SPAN style="color: black;"&gt;And the field name has been copied and pasted from the alias in previous tables, so it's not a spelling issue. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;It seems like a pretty straight forward thing to do, but it’s not working. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;I've also tried scouring the forums, and I see lots of other posts, and people gleefully using exists() in this way, but it doesn't seem to work for me.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;Help?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 23 Oct 2012 18:14:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/EXISTS-agony/m-p/445610#M166238</guid>
      <dc:creator />
      <dc:date>2012-10-23T18:14:27Z</dc:date>
    </item>
    <item>
      <title>Re: EXISTS() agony</title>
      <link>https://community.qlik.com/t5/QlikView/EXISTS-agony/m-p/445611#M166239</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If I am understanding, you are loading some data:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;... AS [Member ID]&lt;/P&gt;&lt;P&gt;...;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then you are trying to load only desired rows from a database something like this...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;V_ID as [Member ID]&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The exist statement should look like this ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;V_ID as [Member ID]&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;WHERE EXISTS([Member ID], V_ID);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The first parameter in the exist clause references the previously loaded data (after any aliasing) and the second parameter references the field (before aliasing) from the current table you are loading.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 23 Oct 2012 18:57:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/EXISTS-agony/m-p/445611#M166239</guid>
      <dc:creator />
      <dc:date>2012-10-23T18:57:19Z</dc:date>
    </item>
  </channel>
</rss>

