<?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 Re: Incremental load without a unique sequential id and modification date in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629707#M679040</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This example works on SQL Server, but achievable in other DBMS.&lt;/P&gt;&lt;P&gt;SELECT * is just example &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;. Read it like SELECT {MyFieldsList}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 28 May 2014 12:01:03 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-05-28T12:01:03Z</dc:date>
    <item>
      <title>Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629701#M679034</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a data loading situation were I'm stuck with, so I hope some off you can help me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For almost all our customers we use a incremental load approach based on a unique sequential id or modification date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unfortunately with this customer there is no unique sequential id (by combining 3 fields we can create a unique key but it is not sequential) and there is no modification date. There is a date field but we cannot use it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I cannot use Where Exists with the SQL statement.&lt;/P&gt;&lt;P&gt;The base QVD has about 4,5 million entries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unfortunately we can also not create a additional field in the database with a trigger or something.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anyone suggest an approach?&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>Tue, 27 May 2014 15:58:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629701#M679034</guid>
      <dc:creator>jjordaan</dc:creator>
      <dc:date>2014-05-27T15:58:30Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629702#M679035</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The only way I know of is to create a hash key from all the fields (or at least all non-key fields). You can use the three fields that combine to a unique key to keep track of new or removed items. You can check for each key value if the calculated hash has changed. If the hash value is different at least one field has a new value. &lt;A href="https://community.qlik.com/qlik-users/71251"&gt;Barry Harmsen&lt;/A&gt; wrote a bit about it here: www.qlikfix.com/2014/03/11/hash-functions-collisions/&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 May 2014 16:44:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629702#M679035</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2014-05-27T16:44:46Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629703#M679036</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Jeroen.&lt;/P&gt;&lt;P&gt;4,5 million entries may be loaded without any conditions.&lt;/P&gt;&lt;P&gt;In most cases, this approach is faster on the tables of this type.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The only thing that can be used to implement incremental load is the row number.&amp;nbsp; But this approach will not work with UPDATE statment.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry, but my english so so.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 May 2014 17:13:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629703#M679036</guid>
      <dc:creator />
      <dc:date>2014-05-27T17:13:15Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629704#M679037</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gysbert,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have also thought about that but without testing it I think it would be performance intensive because it needs to verify record per record.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But if it is the only solution then I have no choice&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 May 2014 11:15:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629704#M679037</guid>
      <dc:creator>jjordaan</dc:creator>
      <dc:date>2014-05-28T11:15:08Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629705#M679038</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Alexander,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The thing also is that this customer has multiple stores around the world so NOT loading incremental is not an option.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you be a bit more specific about your idea with rownumber?&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>Wed, 28 May 2014 11:16:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629705#M679038</guid>
      <dc:creator>jjordaan</dc:creator>
      <dc:date>2014-05-28T11:16:38Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629706#M679039</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jeroen, I mean the following implementation:&lt;/P&gt;&lt;P&gt;tempRowsNo:&lt;/P&gt;&lt;P&gt;LOAD RowNo() as ID&lt;/P&gt;&lt;P&gt;From MyTable.qvd(qvd);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tempRowsNum:&lt;/P&gt;&lt;P&gt;first 1 LOAD&amp;nbsp; ID as RowsNum&lt;/P&gt;&lt;P&gt;Resident tempRowsNo&lt;/P&gt;&lt;P&gt;Order By ID desc;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP Table tempRowsNo;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET vRowsNum = peek('RowsNum',0,'tempRowsNum');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP Table tempRowsNum;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Diff:&lt;/P&gt;&lt;P&gt;LOAD *;&lt;/P&gt;&lt;P&gt;SQL SELECT * FROM MyTable&lt;/P&gt;&lt;P&gt;EXCEPT&lt;/P&gt;&lt;P&gt;SELECT TOP $(vRowsNum ) * FROM MyTable;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 May 2014 11:49:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629706#M679039</guid>
      <dc:creator />
      <dc:date>2014-05-28T11:49:56Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629707#M679040</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This example works on SQL Server, but achievable in other DBMS.&lt;/P&gt;&lt;P&gt;SELECT * is just example &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;. Read it like SELECT {MyFieldsList}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 May 2014 12:01:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629707#M679040</guid>
      <dc:creator />
      <dc:date>2014-05-28T12:01:03Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629708#M679041</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you're right. Calculating a hash for primary key fields doesn't tell you what has changed and including all fields that may have been modified comes down to reading all records anyway.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Isn't there a technique in RDBMS to define triggers that add your virtual primary keys to a new (delta) table whenever a record changes in the original table? Could serve as a delta index.&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 May 2014 12:28:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629708#M679041</guid>
      <dc:creator>Peter_Cammaert</dc:creator>
      <dc:date>2014-05-28T12:28:32Z</dc:date>
    </item>
    <item>
      <title>Re: Incremental load without a unique sequential id and modification date</title>
      <link>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629709#M679042</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you all for your time to help me with this topic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To resolve this issue I did the following.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After gathering information about the database it seems that there is a field which is unique and sequential but only per category.&lt;/P&gt;&lt;P&gt;So I created a loop per category which fetching the highest number for every category.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Again thank you for all your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 17 Aug 2014 12:45:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Incremental-load-without-a-unique-sequential-id-and-modification/m-p/629709#M679042</guid>
      <dc:creator>jjordaan</dc:creator>
      <dc:date>2014-08-17T12:45:55Z</dc:date>
    </item>
  </channel>
</rss>

