<?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 two tables and WHERE in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Joining-two-tables-and-WHERE/m-p/162539#M36025</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two tables:&lt;/P&gt;&lt;P&gt;Table1:&lt;BR /&gt;Date, OriginID,DestID&lt;BR /&gt;2/1/2010,3345,USFF&lt;BR /&gt;3/5/2009,4453,USXX&lt;BR /&gt;2/23/2010,2123,USCC&lt;/P&gt;&lt;P&gt;Table2:&lt;BR /&gt;OriginID,Value,ValidOn,ValidTo&lt;BR /&gt;3345,dddd,12/31/2009,4/30/2010&lt;BR /&gt;3345,ffff,1/1/2009,12/30/2009&lt;BR /&gt;4453,dddd,12/31/2009,4/30/2010&lt;BR /&gt;4453,ffff,1/1/2009,12/30/2009&lt;BR /&gt;2123,dddd,12/31/2009,4/30/2010&lt;BR /&gt;2123,ffff,1/1/2009,12/30/2009&lt;/P&gt;&lt;P&gt;I want the end set look like this:&lt;BR /&gt;TableEND:&lt;BR /&gt;Date, OriginID,DestID,Value&lt;BR /&gt;2/1/2010,3345,USFF, dddd&lt;BR /&gt;3/5/2009,4453,USXX,ffff&lt;BR /&gt;2/23/2010,2123,USCC,dddd&lt;/P&gt;&lt;P&gt;I need make a WHERE statement where i look for Table1.Date field between Table2.ValidOn and Table2.ValidTo.&lt;/P&gt;&lt;P&gt;When I try to join them together then use a resident to filter out what i don't need, i run into memory issues. In reality Table1 and Table2 are pretty big. I tried to join them with a KEEP statement, but again, you can't really use the fields from table1 to filter on what you add in from table2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 16 Aug 2010 15:56:20 GMT</pubDate>
    <dc:creator>gardan</dc:creator>
    <dc:date>2010-08-16T15:56:20Z</dc:date>
    <item>
      <title>Joining two tables and WHERE</title>
      <link>https://community.qlik.com/t5/QlikView/Joining-two-tables-and-WHERE/m-p/162539#M36025</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two tables:&lt;/P&gt;&lt;P&gt;Table1:&lt;BR /&gt;Date, OriginID,DestID&lt;BR /&gt;2/1/2010,3345,USFF&lt;BR /&gt;3/5/2009,4453,USXX&lt;BR /&gt;2/23/2010,2123,USCC&lt;/P&gt;&lt;P&gt;Table2:&lt;BR /&gt;OriginID,Value,ValidOn,ValidTo&lt;BR /&gt;3345,dddd,12/31/2009,4/30/2010&lt;BR /&gt;3345,ffff,1/1/2009,12/30/2009&lt;BR /&gt;4453,dddd,12/31/2009,4/30/2010&lt;BR /&gt;4453,ffff,1/1/2009,12/30/2009&lt;BR /&gt;2123,dddd,12/31/2009,4/30/2010&lt;BR /&gt;2123,ffff,1/1/2009,12/30/2009&lt;/P&gt;&lt;P&gt;I want the end set look like this:&lt;BR /&gt;TableEND:&lt;BR /&gt;Date, OriginID,DestID,Value&lt;BR /&gt;2/1/2010,3345,USFF, dddd&lt;BR /&gt;3/5/2009,4453,USXX,ffff&lt;BR /&gt;2/23/2010,2123,USCC,dddd&lt;/P&gt;&lt;P&gt;I need make a WHERE statement where i look for Table1.Date field between Table2.ValidOn and Table2.ValidTo.&lt;/P&gt;&lt;P&gt;When I try to join them together then use a resident to filter out what i don't need, i run into memory issues. In reality Table1 and Table2 are pretty big. I tried to join them with a KEEP statement, but again, you can't really use the fields from table1 to filter on what you add in from table2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Aug 2010 15:56:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Joining-two-tables-and-WHERE/m-p/162539#M36025</guid>
      <dc:creator>gardan</dc:creator>
      <dc:date>2010-08-16T15:56:20Z</dc:date>
    </item>
    <item>
      <title>Joining two tables and WHERE</title>
      <link>https://community.qlik.com/t5/QlikView/Joining-two-tables-and-WHERE/m-p/162540#M36026</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Something like this:&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;BR /&gt;Table1:&lt;BR /&gt;load * inline [&lt;BR /&gt;Date, OriginID,DestID&lt;BR /&gt;2/1/2010,3345,USFF&lt;BR /&gt;3/5/2009,4453,USXX&lt;BR /&gt;2/23/2010,2123,USCC&lt;BR /&gt;];&lt;BR /&gt;&lt;BR /&gt;Table2:&lt;BR /&gt;load * inline [&lt;BR /&gt;OriginID,Value,ValidOn,ValidTo&lt;BR /&gt;3345,dddd,12/31/2009,4/30/2010&lt;BR /&gt;3345,ffff,1/1/2009,12/30/2009&lt;BR /&gt;4453,dddd,12/31/2009,4/30/2010&lt;BR /&gt;4453,ffff,1/1/2009,12/30/2009&lt;BR /&gt;2123,dddd,12/31/2009,4/30/2010&lt;BR /&gt;2123,ffff,1/1/2009,12/30/2009&lt;BR /&gt;];&lt;BR /&gt;&lt;BR /&gt;Left join (Table2)&lt;BR /&gt;intervalmatch (Date, OriginID)&lt;BR /&gt;load ValidOn, ValidTo, OriginID&lt;BR /&gt;resident Table2;&lt;BR /&gt;&lt;BR /&gt;left join (Table1)&lt;BR /&gt;load OriginID, Date, Value&lt;BR /&gt;resident Table2;&lt;BR /&gt;&lt;BR /&gt;drop table Table2;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Aug 2010 19:05:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Joining-two-tables-and-WHERE/m-p/162540#M36026</guid>
      <dc:creator />
      <dc:date>2010-08-16T19:05:21Z</dc:date>
    </item>
    <item>
      <title>Joining two tables and WHERE</title>
      <link>https://community.qlik.com/t5/QlikView/Joining-two-tables-and-WHERE/m-p/162541#M36027</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Aug 2010 19:16:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Joining-two-tables-and-WHERE/m-p/162541#M36027</guid>
      <dc:creator>gardan</dc:creator>
      <dc:date>2010-08-16T19:16:17Z</dc:date>
    </item>
  </channel>
</rss>

