<?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 Load order gets lost in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Load-order-gets-lost/m-p/490894#M693766</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a situation where I pull one salesorder out of Oracle with SQL (select * from orders where order = 'xxx') then the data is returned in order (load order is equal to SQL result set order) . Line 1 of the sales order at the top and line 10 at the bottom. The data is larger and has a more complex key, but this should explain it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can also write the above resident table to QVD and read it back in and the load order is preserved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If however I pull more data (select * from orders) - write to QVD and read back in - then filter on sales order xxx and then reduce data - my load order is lost. Line 3 might be the first row I see. Any idea why this might happen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My work around is to add Oracle's rownum into my select to use later in the process (select *,rownum from orders), but I would prefer not to have to do this or at least understand why this is happening.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 17 Jul 2013 12:28:35 GMT</pubDate>
    <dc:creator>jarno_loubser</dc:creator>
    <dc:date>2013-07-17T12:28:35Z</dc:date>
    <item>
      <title>Load order gets lost</title>
      <link>https://community.qlik.com/t5/QlikView/Load-order-gets-lost/m-p/490894#M693766</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a situation where I pull one salesorder out of Oracle with SQL (select * from orders where order = 'xxx') then the data is returned in order (load order is equal to SQL result set order) . Line 1 of the sales order at the top and line 10 at the bottom. The data is larger and has a more complex key, but this should explain it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can also write the above resident table to QVD and read it back in and the load order is preserved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If however I pull more data (select * from orders) - write to QVD and read back in - then filter on sales order xxx and then reduce data - my load order is lost. Line 3 might be the first row I see. Any idea why this might happen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My work around is to add Oracle's rownum into my select to use later in the process (select *,rownum from orders), but I would prefer not to have to do this or at least understand why this is happening.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jul 2013 12:28:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-order-gets-lost/m-p/490894#M693766</guid>
      <dc:creator>jarno_loubser</dc:creator>
      <dc:date>2013-07-17T12:28:35Z</dc:date>
    </item>
    <item>
      <title>Re: Load order gets lost</title>
      <link>https://community.qlik.com/t5/QlikView/Load-order-gets-lost/m-p/490895#M693767</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Because reducing data moves remaining rows to new tables in memory and the original are deleted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You should never rely on load sort. If the sort order is important to you, use rownum in query or RowNo() in QlikView load.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jul 2013 12:36:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-order-gets-lost/m-p/490895#M693767</guid>
      <dc:creator>luciancotea</dc:creator>
      <dc:date>2013-07-17T12:36:49Z</dc:date>
    </item>
    <item>
      <title>Re: Load order gets lost</title>
      <link>https://community.qlik.com/t5/QlikView/Load-order-gets-lost/m-p/490896#M693768</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK - QlikView actually preserves the load order perfectly. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I found the actual issue - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My issue was that if the SQL query is not sorted specifically (order by clause), then although the sorting seams in order with a where clause in place it does not mean that all data will be returned in the order required without specifying it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Referring to my example above the issue was resolved by a simple order by clause - "select * from orders order by order, line"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This can then be written to QVD and read in and the order remains.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Jul 2013 11:48:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-order-gets-lost/m-p/490896#M693768</guid>
      <dc:creator>jarno_loubser</dc:creator>
      <dc:date>2013-07-18T11:48:09Z</dc:date>
    </item>
  </channel>
</rss>

