<?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 Loading Data based upon values in an initial load. in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290088#M107675</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think you mean something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Phase2:&lt;/P&gt;&lt;P&gt;load distinct&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Entity ID],&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;where exist([Entity ID],[Entity ID]) ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; SQL SELECT "Entity ID"&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;FROM show_all_br where pid=1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;Qlikview is now looking if the string already exists.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;Succes!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;Halmar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 09 Dec 2011 11:28:53 GMT</pubDate>
    <dc:creator />
    <dc:date>2011-12-09T11:28:53Z</dc:date>
    <item>
      <title>Loading Data based upon values in an initial load.</title>
      <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290087#M107674</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hope someone can assist in this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Initial load of a data set contains values I want to use to go and fetch a secondary data set. Not sure how to approach it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Phase1:&lt;/P&gt;&lt;P&gt;LOAD "Entity ID"as [Entity ID];&lt;/P&gt;&lt;P&gt;&amp;nbsp; SQL SELECT "Entity ID"&lt;/P&gt;&lt;P&gt;FROM show_all_br where pid=1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then for each Entity ID in Phase1: I wish to concatenate the values into a string and&amp;nbsp; run another load for each of the given Entity ID contained in the string.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 09:38:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290087#M107674</guid>
      <dc:creator />
      <dc:date>2011-12-09T09:38:58Z</dc:date>
    </item>
    <item>
      <title>Loading Data based upon values in an initial load.</title>
      <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290088#M107675</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think you mean something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Phase2:&lt;/P&gt;&lt;P&gt;load distinct&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Entity ID],&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;where exist([Entity ID],[Entity ID]) ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; SQL SELECT "Entity ID"&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;FROM show_all_br where pid=1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;Qlikview is now looking if the string already exists.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;Succes!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;Halmar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 11:28:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290088#M107675</guid>
      <dc:creator />
      <dc:date>2011-12-09T11:28:53Z</dc:date>
    </item>
    <item>
      <title>Loading Data based upon values in an initial load.</title>
      <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290089#M107676</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the reply Halmar, I need to describe the problem a little clearer I think.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Query needs to take 3 forms..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) Phase 1 retrieve&amp;nbsp; the Entity ID,&lt;/P&gt;&lt;P&gt;2) Phase 2 For each Entity ID retrieve all the Business Rule ID's&lt;/P&gt;&lt;P&gt;3) Phase 3 For each Business Rule ID retrieve all the failing records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The database is an associative database not pure SQL, but I can use Select (column names) or * and Where clauses but only for a specific set of values .. these are the Entity ID and the Business Rules ID (in this instance)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So Can I retrieve the relevant ID's into memory and then use the In memory ID (via a variable?) to then call the next query? or is there a simpler way of doing it?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So the Logical view is :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Entity_Load:&lt;/P&gt;&lt;P&gt;LOAD DISTINCT "Entity ID";&lt;/P&gt;&lt;P&gt;SQL SELECT "Entity ID",&lt;/P&gt;&lt;P&gt;FROM "show_all_br" where pid=1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Business_Rule_Load:&lt;/P&gt;&lt;P&gt;For each EntityID&lt;/P&gt;&lt;P&gt;&amp;nbsp; LOAD "Bus ID";&lt;/P&gt;&lt;P&gt;&amp;nbsp; SQL SELECT "Bus ID",&lt;/P&gt;&lt;P&gt;&amp;nbsp; FROM "BusRule" where EID="Entity ID" (variable?)&lt;/P&gt;&lt;P&gt;Next EntityID&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Failing Row Load:&lt;/P&gt;&lt;P&gt;For each BusID&amp;nbsp; &lt;/P&gt;&lt;P&gt;LOAD *;&lt;/P&gt;&lt;P&gt;&amp;nbsp; SQL SELECT *,&lt;/P&gt;&lt;P&gt;&amp;nbsp; FROM "FailingRows" where EID="Entity ID" (variable?) &amp;amp; ebr = BusID&lt;/P&gt;&lt;P&gt;Next BusID&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this is a little clearer?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 11:44:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290089#M107676</guid>
      <dc:creator />
      <dc:date>2011-12-09T11:44:43Z</dc:date>
    </item>
    <item>
      <title>Loading Data based upon values in an initial load.</title>
      <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290090#M107677</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do it like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;Entity_Load:&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;LOAD DISTINCT "Entity ID";&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;SQL SELECT "Entity ID",&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;FROM "show_all_br" where pid=1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;left join&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;LOAD&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EID&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as Entity ID&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ebr&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as "Bus ID",&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; *;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; SQL SELECT *,&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; FROM "FailingRows"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You see that you delete the second step.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Halmar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 13:56:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290090#M107677</guid>
      <dc:creator />
      <dc:date>2011-12-09T13:56:53Z</dc:date>
    </item>
    <item>
      <title>Loading Data based upon values in an initial load.</title>
      <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290091#M107678</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks again, still not quite right .. In order to run the second query to fetch the failing rows I must pass in the EID and Bus ID together .. so I need to loop through them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Query so far ... with the data in a view below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="View.jpg" class="jive-image-thumbnail jive-image" onclick="" src="https://community.qlik.com/legacyfs/online/9377_View.jpg" width="450" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The yellow column is the Entity ID, the Green in the Bus ID .. now I need to pass th query in to fetch the failing rows .. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;such as ..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Load *;&lt;/P&gt;&lt;P&gt;Slect * &lt;/P&gt;&lt;P&gt;from Failing_Br where eid=Entity ID and brid = Bus ID;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 14:41:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290091#M107678</guid>
      <dc:creator />
      <dc:date>2011-12-09T14:41:04Z</dc:date>
    </item>
    <item>
      <title>Loading Data based upon values in an initial load.</title>
      <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290092#M107679</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can do this bij using the two fields as a key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;LoadTemp:&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;LOAD DISTINCT "Entity ID";&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;SQL SELECT "Entity ID",&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;FROM "show_all_br" where pid=1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;left join&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt; LOAD &lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;EID as "Entity ID"&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;"Bus ID";&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; SQL SELECT "Bus ID",&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; FROM "BusRule" &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;LoadTemp1:&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;load&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "Entity ID" &amp;amp; '|' "Bus ID"&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as Key&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;resident LoadTemp;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;drop table LoadTemp1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;left join&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;LOAD&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EID &amp;amp; '|' &amp;amp; ebr&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as Key,&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; *;&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; SQL SELECT *,&lt;/P&gt;&lt;P style="background-color: #eef4f9; font-size: 12px; color: #636363; font-family: Arial;"&gt;&amp;nbsp; FROM "FailingRows" ;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 16:18:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290092#M107679</guid>
      <dc:creator />
      <dc:date>2011-12-09T16:18:04Z</dc:date>
    </item>
    <item>
      <title>Loading Data based upon values in an initial load.</title>
      <link>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290093#M107680</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I cant use that Halmar.. the where Clause has to contain both Entity ID and Bus ID or it will not run..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Such as below ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD *;&lt;/P&gt;&lt;P&gt;SQL SELECT *&lt;/P&gt;&lt;P&gt;FROM "view_br_fail" where eid=8 and ebr=4;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I need to iterate throught each Entity ID(eid) and then Each Bus ID (ebr) it contains&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Dec 2011 17:52:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Loading-Data-based-upon-values-in-an-initial-load/m-p/290093#M107680</guid>
      <dc:creator />
      <dc:date>2011-12-09T17:52:42Z</dc:date>
    </item>
  </channel>
</rss>

