<?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 Joining tables in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Joining-tables/m-p/560078#M1144239</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;I have query (a complex query), call it query "X", in SQL server wich I load into TableA. (The load takes failrly long)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I then load from another query, call it query "Y", that contains query "X" and additional tables into TableB. &lt;/P&gt;&lt;P&gt;(This query takes much longer because it contains query "X" as one of the components.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think I can speed up the load by simplifying query "Y" by omitting query "X" and make the join in the load using Resident TableA since it is already loaded.&lt;/P&gt;&lt;P&gt;I do need though some fields from TableA and additionals from query "Y" to create TableB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am stuck with how to join the tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the scenario:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Qualify *;&lt;/P&gt;&lt;P&gt;Unqualify a;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TableA:&lt;/P&gt;&lt;P&gt;LOAD a, b, c, d&lt;/P&gt;&lt;P&gt;FROM query X;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TableB:&lt;/P&gt;&lt;P&gt;LOAD a, b, c, x, y, z&lt;/P&gt;&lt;P&gt;FROM query Y &lt;STRONG style="color: #ff0000;"&gt;LEFT JOIN&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; query X on Y.a = X.a&lt;/SPAN&gt;;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to change the LEFT JOIN portion and instead use Resident TableA instead, keeping in mind that I need to bring fields b and c from TableA into TableB?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your input.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 05 Aug 2013 22:31:44 GMT</pubDate>
    <dc:creator>jduenyas</dc:creator>
    <dc:date>2013-08-05T22:31:44Z</dc:date>
    <item>
      <title>Joining tables</title>
      <link>https://community.qlik.com/t5/QlikView/Joining-tables/m-p/560078#M1144239</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;I have query (a complex query), call it query "X", in SQL server wich I load into TableA. (The load takes failrly long)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I then load from another query, call it query "Y", that contains query "X" and additional tables into TableB. &lt;/P&gt;&lt;P&gt;(This query takes much longer because it contains query "X" as one of the components.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think I can speed up the load by simplifying query "Y" by omitting query "X" and make the join in the load using Resident TableA since it is already loaded.&lt;/P&gt;&lt;P&gt;I do need though some fields from TableA and additionals from query "Y" to create TableB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am stuck with how to join the tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the scenario:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Qualify *;&lt;/P&gt;&lt;P&gt;Unqualify a;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TableA:&lt;/P&gt;&lt;P&gt;LOAD a, b, c, d&lt;/P&gt;&lt;P&gt;FROM query X;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TableB:&lt;/P&gt;&lt;P&gt;LOAD a, b, c, x, y, z&lt;/P&gt;&lt;P&gt;FROM query Y &lt;STRONG style="color: #ff0000;"&gt;LEFT JOIN&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; query X on Y.a = X.a&lt;/SPAN&gt;;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to change the LEFT JOIN portion and instead use Resident TableA instead, keeping in mind that I need to bring fields b and c from TableA into TableB?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your input.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Aug 2013 22:31:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Joining-tables/m-p/560078#M1144239</guid>
      <dc:creator>jduenyas</dc:creator>
      <dc:date>2013-08-05T22:31:44Z</dc:date>
    </item>
    <item>
      <title>Re: Joining tables</title>
      <link>https://community.qlik.com/t5/QlikView/Joining-tables/m-p/560079#M1144240</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Qualify *;&lt;/P&gt;&lt;P&gt;Unqualify a;&lt;/P&gt;&lt;P&gt;TableA:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD a, b, c, d&lt;/P&gt;&lt;P&gt;FROM query X;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TableTemp:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Load a,b,c Resident TableA;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Right Join (TableTemp) // qlikview joins on common field (here,'a'), so don't have to mention it explicitly&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TableB:&lt;/P&gt;&lt;P&gt;LOAD a, x, y, z&lt;/P&gt;&lt;P&gt;FROM query Y &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Drop Table TableTemp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Aug 2013 04:31:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Joining-tables/m-p/560079#M1144240</guid>
      <dc:creator>tresB</dc:creator>
      <dc:date>2013-08-06T04:31:53Z</dc:date>
    </item>
  </channel>
</rss>

