<?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 JOIN query in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208143#M882467</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt; but it is taking long time to load&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&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;which statement?&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: 13px;"&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: 13px;"&gt;maybe an option could be to join in SQL the 3 tables using (&lt;STRONG&gt;in SQL&lt;/STRONG&gt;) the vDate filter&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 08 Oct 2016 11:00:08 GMT</pubDate>
    <dc:creator>maxgro</dc:creator>
    <dc:date>2016-10-08T11:00:08Z</dc:date>
    <item>
      <title>SQL JOIN query</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208142#M882466</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Experts,&lt;/P&gt;&lt;P&gt;In SAP, as shown below, we have following four tables, in which Key field is available in all tables. &lt;/P&gt;&lt;P&gt;And I want to fetch the records of third &amp;amp; fourth table if Creation / Change Date is yesterday’s date in first two tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" style="width: 389px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt; Table&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; border-left: none; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;Key Field&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; border-left: none; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="118"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;Creation Date&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; border-left: none; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="108"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;Change Date&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; border-top: none; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;AFRU&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;AUFPL&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="118"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;ERSDA&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="108"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; border-top: none; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;CAUFV&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;AUFPL&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="118"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;ERDAT&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="108"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;AEDAT&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; border-top: none; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;AFVV&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;AUFPL&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="118"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="108"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD nowrap="nowrap" style="border: solid windowtext 1.0pt; border-top: none; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;AFVC&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="81"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt;AUFPL&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="118"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD nowrap="nowrap" style="border-top: none; border-left: none; border-bottom: solid windowtext 1.0pt; border-right: solid windowtext 1.0pt; padding: 0 5.4pt 0 5.4pt;" valign="bottom" width="108"&gt;&lt;P align="center" style="text-align: center;"&gt;&lt;SPAN style="color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Existing script is as given below, but it is taking long time to load.&lt;/P&gt;&lt;P&gt;Is there any better way to join tables?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;AFRU:&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;Load&lt;/STRONG&gt; &lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt;&lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; SELECT DISTINCT AUFPL FROM AFRU WHERE ERSDA&amp;nbsp; &amp;gt;= '$(vDate)';&lt;BR /&gt; &lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;Join&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; (AFRU)&lt;BR /&gt; CAUFV:&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;Load&lt;/STRONG&gt; &lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; SELECT AUFPL FROM CAUFV WHERE (CAUFV~ERDAT &amp;gt;= '$(vDate)' OR CAUFV~AEDAT &amp;gt;= '$(vDate)');&lt;BR /&gt; &lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;LEFT&lt;/SPAN&gt; &lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;JOIN&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; (AFRU)&lt;BR /&gt; AFVV:&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;Load&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;APLZL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;STEUS&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; SELECT AFVV~AUFPL AFVV~APLZL AFVC~AUFPL AFVC~APLZL AFVC~STEUS&lt;BR /&gt; FROM AFVV INNER JOIN AFVC ON AFVV~AUFPL = AFVC~AUFPL AND AFVV~APLZL = AFVC~APLZL; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Girish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208142#M882466</guid>
      <dc:creator>girish_talele</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: SQL JOIN query</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208143#M882467</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt; but it is taking long time to load&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&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;which statement?&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: 13px;"&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: 13px;"&gt;maybe an option could be to join in SQL the 3 tables using (&lt;STRONG&gt;in SQL&lt;/STRONG&gt;) the vDate filter&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 08 Oct 2016 11:00:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208143#M882467</guid>
      <dc:creator>maxgro</dc:creator>
      <dc:date>2016-10-08T11:00:08Z</dc:date>
    </item>
    <item>
      <title>Re: SQL JOIN query</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208144#M882468</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;Dear Maxgro,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;Thanks for looking into, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;Script is taking long time in Third &amp;amp; Fourth table, there are almost 1.5 Million records loaded (WHERE condition also not applicable),&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;whereas only 13 K records are matching with key field laded in first &amp;amp; second table. It takes almost 8-10 Min to load,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;If I use separate left join i.e. (as given below)&lt;/SPAN&gt;&lt;/P&gt;&lt;OL style="list-style-type: decimal;"&gt;&lt;LI&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;1. Left Join AFRU &amp;amp; AFVV,&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;2. Left Join CAUFV &amp;amp; AFVV&lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;Then the data is getting fetched in 1 Min only. But I want load the same in one go.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Arial, sans-serif; font-size: 10pt;"&gt;Girish.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;AFRU:&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;Load&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;APLZL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;STEUS&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; SELECT DISTINCT CAUFV~AUFPL&lt;BR /&gt; AFVV~AUFPL AFVV~APLZL &lt;BR /&gt; AFVC~AUFPL AFVC~APLZL AFVC~STEUS&lt;BR /&gt; &lt;BR /&gt; FROM CAUFV &lt;BR /&gt; &lt;BR /&gt; LEFT JOIN AFVV ON&amp;nbsp; CAUFV~AUFPL = AFVV~AUFPL&lt;BR /&gt; INNER JOIN AFVC ON&amp;nbsp; AFVV~AUFPL = AFVC~AUFPL AND AFVV~APLZL = AFVC~APLZL&lt;BR /&gt; &lt;BR /&gt; WHERE (CAUFV~ERDAT &amp;gt;= '$(vLastLoadDate)' OR CAUFV~AEDAT &amp;gt;= '$(vLastLoadDate)');&lt;BR /&gt; &lt;BR /&gt; //--------------------------------------------------------------------------------------------------------------&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;AFRU:&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;Load&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;APLZL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;STEUS&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; SELECT DISTINCT AFRU~AUFPL&lt;BR /&gt; AFVV~AUFPL AFVV~APLZL &lt;BR /&gt; AFVC~AUFPL AFVC~APLZL AFVC~STEUS&lt;BR /&gt; &lt;BR /&gt; FROM AFRU &lt;BR /&gt; LEFT JOIN AFVV ON&amp;nbsp; AFRU~AUFPL = AFVV~AUFPL&lt;BR /&gt; INNER JOIN AFVC ON&amp;nbsp; AFVV~AUFPL = AFVC~AUFPL AND AFVV~APLZL = AFVC~APLZL&lt;BR /&gt; &lt;BR /&gt; WHERE ERSDA&amp;nbsp; &amp;gt;= '$(vLastLoadDate)';&lt;BR /&gt; &lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 08 Oct 2016 12:20:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208144#M882468</guid>
      <dc:creator>girish_talele</dc:creator>
      <dc:date>2016-10-08T12:20:12Z</dc:date>
    </item>
    <item>
      <title>Re: SQL JOIN query</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208145#M882469</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Might this problem you are facing is performance. The reason was you are getting data From different source. I would request you to store this Two table s into qvd and then try to reload. Check whether you will get reduced the elapsed time or not and let me know what's the file size and qvw file size&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 08 Oct 2016 12:51:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208145#M882469</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2016-10-08T12:51:39Z</dc:date>
    </item>
    <item>
      <title>Re: SQL JOIN query</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208146#M882470</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I hope to understand.&lt;/P&gt;&lt;P&gt;If it takes long time in SQL (below), it could be the database and/or the network&lt;/P&gt;&lt;P&gt;One way to reduce (maybe the only one) is to reduce the record Qlik get from the database &lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt; SELECT AFVV~AUFPL AFVV~APLZL AFVC~AUFPL AFVC~APLZL AFVC~STEUS&lt;BR /&gt;FROM AFVV INNER JOIN AFVC ON AFVV~AUFPL = AFVC~AUFPL AND AFVV~APLZL = AFVC~APLZL;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;I think something like (check the syntax)&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;STRONG style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt; SELECT AFVV~AUFPL AFVV~APLZL AFVC~AUFPL AFVC~APLZL AFVC~STEUS&lt;BR /&gt;FROM AFVV INNER JOIN AFVC ON AFVV~AUFPL = AFVC~AUFPL AND AFVV~APLZL = AFVC~APLZL&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;WHERE &lt;SPAN style="color: #000000; font-family: 'Courier New'; font-size: 12px;"&gt;AFVV~AUFPL in &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;// this should be the same as your first 2 statements (see below, full ouer join ***)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;(&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SELECT DISTINCT AUFPL FROM AFRU WHERE ERSDA&amp;nbsp; &amp;gt;= '$(vDate)'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; UNION&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SELECT AUFPL FROM CAUFV WHERE (CAUFV~ERDAT &amp;gt;= '$(vDate)' OR CAUFV~AEDAT &amp;gt;= '$(vDate)')&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;***&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;&lt;EM&gt;AFRU:&lt;/EM&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;EM&gt;&lt;STRONG style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;Load&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt;&lt;/SPAN&gt;&lt;STRONG style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt; SELECT DISTINCT AUFPL FROM AFRU WHERE ERSDA&amp;nbsp; &amp;gt;= '$(vDate)';&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;Join&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt; (AFRU)&lt;BR /&gt;CAUFV:&lt;BR /&gt;&lt;/SPAN&gt;&lt;STRONG style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;Load&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt;&lt;/SPAN&gt;&lt;STRONG style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt; SELECT AUFPL FROM CAUFV WHERE (CAUFV~ERDAT &amp;gt;= '$(vDate)' OR CAUFV~AEDAT &amp;gt;= '$(vDate)');&lt;/SPAN&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 08 Oct 2016 12:52:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208146#M882470</guid>
      <dc:creator>maxgro</dc:creator>
      <dc:date>2016-10-08T12:52:38Z</dc:date>
    </item>
    <item>
      <title>Re: SQL JOIN query</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208147#M882471</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Massimo,&lt;/P&gt;&lt;P&gt;Thanks again,&lt;/P&gt;&lt;P&gt;I got below error message while running the script.&lt;/P&gt;&lt;P&gt;--&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;-&lt;/P&gt;&lt;P&gt;/QTQVC/OPEN_STREAM failed after 00:00:00 Key = SQL_ERROR (ID:00 Type:E Number:001 Incorrect expression "UNION" in logical condition.)&lt;/P&gt;&lt;P&gt;SQL SELECT AFVV~AUFPL AFVV~APLZL AFVC~AUFPL AFVC~APLZL AFVC~STEUS&lt;/P&gt;&lt;P&gt;FROM AFVV INNER JOIN AFVC ON AFVV~AUFPL = AFVC~AUFPL AND AFVV~APLZL = AFVC~APLZL&lt;/P&gt;&lt;P&gt;WHERE AFVV~AUFPL in&lt;/P&gt;&lt;P&gt;(&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SELECT DISTINCT AUFPL FROM AFRU WHERE ERSDA&amp;nbsp; &amp;gt;= '20161008'&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; UNION&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SELECT AUFPL FROM CAUFV WHERE (CAUFV~ERDAT &amp;gt;= '20161008' OR CAUFV~AEDAT &amp;gt;= '20161008')&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;SPAN lang="EN-US" style="font-size: 11.0pt; font-family: 'Calibri','sans-serif';"&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 11.0pt; font-family: 'Calibri','sans-serif';"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;--&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;SPAN style="font-size: 13.3333px;"&gt;------&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;-&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Modified your script as given below.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;AFRU:&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;Load&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;AUFPL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;APLZL&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;,&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;STEUS&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;;&lt;BR /&gt; &lt;/SPAN&gt;&lt;STRONG style="color: blue; font-size: 9.0pt; font-family: 'Courier New';"&gt;SQL&lt;/STRONG&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; SELECT AFVV~AUFPL AFVV~APLZL AFVC~AUFPL AFVC~APLZL AFVC~STEUS&lt;BR /&gt; FROM AFVV INNER JOIN AFVC ON AFVV~AUFPL = AFVC~AUFPL AND AFVV~APLZL = AFVC~APLZL&lt;BR /&gt; WHERE AFVV~AUFPL in&lt;BR /&gt; (SELECT DISTINCT AUFPL FROM AFRU WHERE ERSDA&amp;nbsp; &amp;gt;= '$(vDate)')&lt;BR /&gt; &lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: green;"&gt;&lt;STRONG&gt;//&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; UNION&lt;/STRONG&gt;&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt; OR&lt;/STRONG&gt; &lt;BR /&gt; AFVV~AUFPL in&lt;BR /&gt; (SELECT AUFPL FROM CAUFV WHERE (CAUFV~ERDAT &amp;gt;= '$(vDate)' OR CAUFV~AEDAT &amp;gt;= '$(vDate)'));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;*** Instead of Union, I used OR statement &lt;SPAN style="font-size: 13.3333px;"&gt;&amp;amp; it worked fine.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Although with OR statement I am getting the results, had one query - What was the use of UNION in your script? How to remove the error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; regards,&lt;/P&gt;&lt;P&gt;Girish.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Oct 2016 05:54:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-JOIN-query/m-p/1208147#M882471</guid>
      <dc:creator>girish_talele</dc:creator>
      <dc:date>2016-10-10T05:54:46Z</dc:date>
    </item>
  </channel>
</rss>

