<?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: SQL exists in Qlikview in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768429#M272896</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks for your proffesional answer! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can you please clariy this statement?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;TempFact:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;SQL SELECT * FROM Fact; // Completely relieve the DB. QV can handle many rows&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;"&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-style: inherit; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;l logic Why do u put SQL before it? what is the meaning?&lt;BR /&gt;&lt;/SPAN&gt;&lt;BR /&gt;i plan to load it from a qvd, so isn't it better to load from a qvd?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 11 Jan 2015 13:30:49 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-01-11T13:30:49Z</dc:date>
    <item>
      <title>SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768420#M272887</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 am trying to create a logic that i have worked out in SQL,&lt;/P&gt;&lt;P&gt;but i don't know how to craete it in qlikview script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a table that describes ads, on a dialy level,&lt;/P&gt;&lt;P&gt;which says if the ad had an Upgrade ad (there are many types of upgrades, like: boost, premiumm, etc.),&lt;/P&gt;&lt;P&gt;or a base ad,&lt;/P&gt;&lt;P&gt;my goal is to take only premium ads WHICH HAD IN THE SAME DAY a basic ad&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;table name: Fact&lt;/P&gt;&lt;P&gt;Columns: id, upgarde, date&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;SELECT *&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;FROM Fact AS a&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;WHERE (a.upgrade='premium' OR &lt;SPAN style="font-size: 13.3333330154419px;"&gt;a.upgrade='boost')&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;EXISTS (SELECT * FROM Fact AS b&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WHERE upgrade='basic' AND a.id=b.id AND a.date=b.date)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*note: there a 10 types of premium, so i may see situations like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;column: id, upgrade, date&lt;/P&gt;&lt;P&gt;values: 123, basic, 1.1.2015&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 123, premium, 1.1.2015&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 123, boost, 1.1.2015&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 11:14:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768420#M272887</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-11T11:14:52Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768421#M272888</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Be aware that you can write your full SQL syntax that is supported by your SQL database for everything that you write in a SQL statement between the keyword SQL and the following semicolon in your Load Script. Like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; font-size: 12pt; font-family: 'courier new', courier;"&gt;SQL&amp;nbsp; // all lines until the semicolon are sent unmodifed to your SQL DB:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; SELECT *&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;STRONG style="font-size: 10pt; font-style: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FROM Fact AS a&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;STRONG&gt;&lt;SPAN style="color: #3d3d3d;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;WHERE (a.upgrade='premium' OR &lt;SPAN style="font-style: inherit; font-size: 13.3333330154419px;"&gt;a.upgrade='boost')&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EXISTS (SELECT * &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;STRONG&gt;&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FROM Fact AS b&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;STRONG&gt;&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WHERE upgrade='basic' AND a.id=b.id AND a.date=b.date)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style=": ; font-size: 12pt; font-family: 'courier new', courier;"&gt;;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;However you might not have a SQL database at all - please let us know and then we can advice on how to do the &lt;BR /&gt;same logic in a Load Script without a SQL datasource.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 11:35:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768421#M272888</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2015-01-11T11:35:44Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768422#M272889</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have, but I don't want to over load the SQL server,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;isn't it most optimized when i pull it to a qvd, and work on it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 11:39:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768422#M272889</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-11T11:39:37Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768423#M272890</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The SQL Exists does not exist in QlikView - you do have and Exists inter-record function which word wise might lead you into thinking it is very similar... But it works on only values that at the point of execution are present in a specific field in memory. Exists in SQL works on the entire set of records in a result query and will return entire rows not a single column.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 11:40:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768423#M272890</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2015-01-11T11:40:11Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768424#M272891</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes that is one main reasons for using QVD. Then you keep a history in QVD's and consolidate by using pure Load Script functionality. Unless you install a free to use "express" type of SQL database for staging purposes. Then you can still use your SQL skills to get a solution.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 11:42:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768424#M272891</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2015-01-11T11:42:37Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768425#M272892</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;excellent,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;do u have an idea how to do it in Qlikview?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 11:46:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768425#M272892</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-11T11:46:21Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768426#M272893</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In a QVD-scenario you will have to make the QlikView Exists work and it depends on a single field match. To achieve this you will have to have a new field which is a concatenation of the three key fields in your SQL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Upgrade, ID and Date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD SCRIPT suggestions:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Fact:&amp;nbsp;&amp;nbsp;&amp;nbsp; // The population of your intial Fact&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; id &amp;amp; '|' &amp;amp; upgrade &amp;amp; '|' &amp;amp; Num(date)&amp;nbsp; AS [%MatchKey],&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; *;&lt;/P&gt;&lt;P&gt;SQL ....... ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then you will use this new [%MatchKey] field to mach history facts to newly arrived facts.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 11:54:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768426#M272893</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2015-01-11T11:54:45Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768427#M272894</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;great,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;correction, i will need to comppose the key only from&amp;nbsp; 2 columns: date, id&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basic:&lt;/P&gt;&lt;P&gt;LOAD id, upgrade, date,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; id &amp;amp; '|' &amp;amp; '|' &amp;amp; Num(date)&amp;nbsp; AS [%MatchKey],&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.3333330154419px;"&gt;FROM qvd;&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.3333330154419px;"&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.3333330154419px;"&gt;LEFT JOIN &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.3333330154419px;"&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.3333330154419px;"&gt;Upgrades:&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.3333330154419px;"&gt;LOAD *&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; id &amp;amp; '|' &amp;amp; '|' &amp;amp; Num(date)&amp;nbsp; AS [%MatchKey],&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.3333330154419px;"&gt;FROM qvd&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.3333330154419px;"&gt;WHERE upgrade Match ('premium','boost')&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.3333330154419px;"&gt;AND Exists (key, key)&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.3333330154419px;"&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.3333330154419px;"&gt;how should i write the last row?&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.3333330154419px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 12:06:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768427#M272894</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-11T12:06:07Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768428#M272895</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Since your original logic ignores upgrades that happen at a later date than the initial basic entry (and that fail the conditions because of not having a basic entry on the same date), you could reverse the steps:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;TempFact:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;SQL SELECT * FROM Fact; // Completely relieve the DB. QV can handle many rows&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Fact:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD&amp;nbsp; id, date, upgrade AS originalupgrade RESIDENT TempFact&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;WHERE upgrade = 'basic';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;INNER JOIN (Fact)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD id, date, upgrade AS newupgrade RESIDENT TempFact&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;WHERE (upgrade = 'premium') OR (upgrade = 'boost') OR ...; // Add the other eight&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;// or create a mapping table&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;// To drop the doubles (a boost and premium on the same day) you'll have &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;// to define an order of precedence&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;// JOIN in the details at the end&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;DROP Table TempFact;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 12:18:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768428#M272895</guid>
      <dc:creator>Peter_Cammaert</dc:creator>
      <dc:date>2015-01-11T12:18:32Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768429#M272896</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks for your proffesional answer! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can you please clariy this statement?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;TempFact:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;SQL SELECT * FROM Fact; // Completely relieve the DB. QV can handle many rows&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;"&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; 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.3333330154419px; font-family: 'courier new', courier;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-style: inherit; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;l logic Why do u put SQL before it? what is the meaning?&lt;BR /&gt;&lt;/SPAN&gt;&lt;BR /&gt;i plan to load it from a qvd, so isn't it better to load from a qvd?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 13:30:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768429#M272896</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-11T13:30:49Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768430#M272897</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It was a guess. Someone has to fetch the data from a database. Inserting a QVD buffer in your data flow is only useful if you either plan to use the QVD in other documents, or you need the source table in the same document many times.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If this is the only time you will be reading the source table, you can do it with this very simple SELECT on the source DB. The overhead on the RDBMS is very low, even for millions of rows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If your situation is different, replace the SQL SELECT with a sub-second QVD read like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;TempFact:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD * FROM [SourceTable.qvd] (qvd); // Optimized LOAD = very fast&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 13:50:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768430#M272897</guid>
      <dc:creator>Peter_Cammaert</dc:creator>
      <dc:date>2015-01-11T13:50:37Z</dc:date>
    </item>
    <item>
      <title>Re: SQL exists in Qlikview</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768431#M272898</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank You&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Jan 2015 14:15:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-exists-in-Qlikview/m-p/768431#M272898</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-11T14:15:46Z</dc:date>
    </item>
  </channel>
</rss>

