<?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 JOIN+LOAD and aliases in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/JOIN-LOAD-and-aliases/m-p/411310#M1159720</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am confronted to a rather trivial scripting problem in QV. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the need of a calculated field, I want to join two QV tables, aliased Alias1 and Alias2 below. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13547617235347941" jivemacro_uid="_13547617235347941"&gt;&lt;P&gt;[Alias1]:&lt;/P&gt;&lt;P&gt;SQL SELECT ... FROM ...;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[Alias2]:&lt;/P&gt;&lt;P&gt;SQL SELECT ... FROM ...;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A JOIN come to the rescue to achieve just that: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13547618013663319" jivemacro_uid="_13547618013663319"&gt;&lt;P&gt;[Alias3]:&lt;/P&gt;&lt;P&gt;INNER JOIN ([Alias2])&lt;/P&gt;&lt;P&gt;LOAD * RESIDENT [Alias1];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP TABLE [Alias1];&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I like the idea of having a seperate QV object that lets me join two existing resident tables. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, what happens in the Table Viewer is the joined fields (Alias1') are added to Alias2, and added fields are prepended with the string "Alias3". I understand the JOIN is actually effective in Alias2, explaining why I cannot drop Alias2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Besides doing: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13547620492643447" jivemacro_uid="_13547620492643447"&gt;&lt;P&gt;[Alias3]:&lt;/P&gt;&lt;P&gt;INNER JOIN (&lt;SPAN style="font-family: 'Lucida Grande', Arial, Helvetica, sans-serif; background-color: #ffffff;"&gt;SQL SELECT ... FROM ...&lt;/SPAN&gt;)&lt;/P&gt;&lt;P&gt;LOAD * &lt;SPAN style="font-family: 'Lucida Grande', Arial, Helvetica, sans-serif; background-color: #ffffff;"&gt;SQL SELECT ... FROM ...;&lt;/SPAN&gt;];&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any way around this? The concern again is to keep two separate entities (with their own SQL queries), that are later joined, and loaded in a new table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 06 Dec 2012 02:50:56 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-12-06T02:50:56Z</dc:date>
    <item>
      <title>JOIN+LOAD and aliases</title>
      <link>https://community.qlik.com/t5/QlikView/JOIN-LOAD-and-aliases/m-p/411310#M1159720</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am confronted to a rather trivial scripting problem in QV. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the need of a calculated field, I want to join two QV tables, aliased Alias1 and Alias2 below. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13547617235347941" jivemacro_uid="_13547617235347941"&gt;&lt;P&gt;[Alias1]:&lt;/P&gt;&lt;P&gt;SQL SELECT ... FROM ...;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[Alias2]:&lt;/P&gt;&lt;P&gt;SQL SELECT ... FROM ...;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A JOIN come to the rescue to achieve just that: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13547618013663319" jivemacro_uid="_13547618013663319"&gt;&lt;P&gt;[Alias3]:&lt;/P&gt;&lt;P&gt;INNER JOIN ([Alias2])&lt;/P&gt;&lt;P&gt;LOAD * RESIDENT [Alias1];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP TABLE [Alias1];&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I like the idea of having a seperate QV object that lets me join two existing resident tables. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, what happens in the Table Viewer is the joined fields (Alias1') are added to Alias2, and added fields are prepended with the string "Alias3". I understand the JOIN is actually effective in Alias2, explaining why I cannot drop Alias2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Besides doing: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13547620492643447" jivemacro_uid="_13547620492643447"&gt;&lt;P&gt;[Alias3]:&lt;/P&gt;&lt;P&gt;INNER JOIN (&lt;SPAN style="font-family: 'Lucida Grande', Arial, Helvetica, sans-serif; background-color: #ffffff;"&gt;SQL SELECT ... FROM ...&lt;/SPAN&gt;)&lt;/P&gt;&lt;P&gt;LOAD * &lt;SPAN style="font-family: 'Lucida Grande', Arial, Helvetica, sans-serif; background-color: #ffffff;"&gt;SQL SELECT ... FROM ...;&lt;/SPAN&gt;];&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any way around this? The concern again is to keep two separate entities (with their own SQL queries), that are later joined, and loaded in a new table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Dec 2012 02:50:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/JOIN-LOAD-and-aliases/m-p/411310#M1159720</guid>
      <dc:creator />
      <dc:date>2012-12-06T02:50:56Z</dc:date>
    </item>
    <item>
      <title>Re: JOIN+LOAD and aliases</title>
      <link>https://community.qlik.com/t5/QlikView/JOIN-LOAD-and-aliases/m-p/411311#M1159721</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;just remove the table name [Alias3] and only use:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE class="jive-code"&gt;[Alias1]:&lt;BR /&gt;SQL SELECT ... FROM ...;&lt;BR /&gt;&lt;BR /&gt;[Alias2]:&lt;BR /&gt;SQL SELECT ... FROM ...;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE class="jive-code"&gt;INNER JOIN ([Alias2])&lt;BR /&gt;LOAD * RESIDENT [Alias1];&lt;BR /&gt;&lt;BR /&gt;DROP TABLE [Alias1];&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now if u want to rename table Alias2, u can use: Rename table Alias 2 to Alias3 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Dec 2012 03:07:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/JOIN-LOAD-and-aliases/m-p/411311#M1159721</guid>
      <dc:creator />
      <dc:date>2012-12-06T03:07:57Z</dc:date>
    </item>
  </channel>
</rss>

