<?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 AW:Cartesian product in QV in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Cartesian-product-in-QV/m-p/177647#M715652</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, you can use simple JOINs for it. But i think, this just works for small amount of data. For your example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;BR /&gt;LOAD&lt;BR /&gt; Field1&lt;BR /&gt;FROM&lt;BR /&gt;Table1;&lt;BR /&gt;&lt;BR /&gt;OUTER JOIN&lt;BR /&gt;&lt;BR /&gt;LOAD Field1 AS Field2&lt;BR /&gt;FROM&lt;BR /&gt; Table2;&lt;BR /&gt;&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;LOAD&lt;BR /&gt; Field1,&lt;BR /&gt; Field2,&lt;BR /&gt; Field3&lt;BR /&gt;FROM&lt;BR /&gt; Table1;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 Dec 2009 21:08:04 GMT</pubDate>
    <dc:creator />
    <dc:date>2009-12-07T21:08:04Z</dc:date>
    <item>
      <title>Cartesian product in QV</title>
      <link>https://community.qlik.com/t5/QlikView/Cartesian-product-in-QV/m-p/177646#M715651</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 would like to create the cartesian product by joining two tables. Table1 is read into QV from a database and the other is generated internally within QV. An example of what I would like to do is:&lt;/P&gt;&lt;DIV&gt;&lt;P&gt;&lt;STRONG&gt;Table1&lt;/STRONG&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;Field1 Field2 Field3&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;1 A 22&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;2 B 71&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;&lt;STRONG&gt;Table2&lt;/STRONG&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;Field2&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;A&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;B&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;C&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;The "join" should result in the following table&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;Field1 Field2 Field3&lt;/P&gt;&lt;P&gt;1 A 22&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;1 B -&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;1 C -&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;2 A -&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;2 B 71&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;2 C -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any suggestions on how this can be done?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;/HJ&lt;/P&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Dec 2009 20:11:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Cartesian-product-in-QV/m-p/177646#M715651</guid>
      <dc:creator>theviking</dc:creator>
      <dc:date>2009-12-07T20:11:20Z</dc:date>
    </item>
    <item>
      <title>AW:Cartesian product in QV</title>
      <link>https://community.qlik.com/t5/QlikView/Cartesian-product-in-QV/m-p/177647#M715652</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, you can use simple JOINs for it. But i think, this just works for small amount of data. For your example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;BR /&gt;LOAD&lt;BR /&gt; Field1&lt;BR /&gt;FROM&lt;BR /&gt;Table1;&lt;BR /&gt;&lt;BR /&gt;OUTER JOIN&lt;BR /&gt;&lt;BR /&gt;LOAD Field1 AS Field2&lt;BR /&gt;FROM&lt;BR /&gt; Table2;&lt;BR /&gt;&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;LOAD&lt;BR /&gt; Field1,&lt;BR /&gt; Field2,&lt;BR /&gt; Field3&lt;BR /&gt;FROM&lt;BR /&gt; Table1;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Dec 2009 21:08:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Cartesian-product-in-QV/m-p/177647#M715652</guid>
      <dc:creator />
      <dc:date>2009-12-07T21:08:04Z</dc:date>
    </item>
    <item>
      <title>AW:Cartesian product in QV</title>
      <link>https://community.qlik.com/t5/QlikView/Cartesian-product-in-QV/m-p/177648#M715653</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks!!! &lt;IMG alt="Big Smile" src="http://community.qlik.com/emoticons/emotion-2.gif" /&gt;&lt;/P&gt;&lt;P&gt;It worked like a charm. The only modification I did was to add a distinct option to the first load statement.&lt;/P&gt;&lt;P&gt;LOAD &lt;STRONG&gt;DISTINCT&lt;/STRONG&gt; Field1&lt;BR /&gt;FROM&lt;BR /&gt;Table1;&lt;BR /&gt;&lt;BR /&gt;OUTER JOIN&lt;BR /&gt;&lt;BR /&gt;LOAD Field1 AS Field2&lt;BR /&gt;FROM&lt;BR /&gt; Table2;&lt;BR /&gt;&lt;BR /&gt;LEFT JOIN&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;BR /&gt; Field1,&lt;BR /&gt; Field2,&lt;BR /&gt; Field3&lt;BR /&gt;FROM&lt;BR /&gt; Table1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Many thanks!&lt;/P&gt;&lt;P&gt;/HJ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Dec 2009 21:40:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Cartesian-product-in-QV/m-p/177648#M715653</guid>
      <dc:creator>theviking</dc:creator>
      <dc:date>2009-12-07T21:40:46Z</dc:date>
    </item>
  </channel>
</rss>

