<?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 with UPDATE and NEW rows without a unique identifier in Archived Groups</title>
    <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821762#M2914</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Close...&amp;nbsp; Assuming you have QVD with the previous data, and a file with the additional/changed data, here is what I see:&lt;BR /&gt;______________________________________________&lt;BR /&gt;CustomerChangeMap:&lt;BR /&gt;MAPPING LOAD DISTINCT&lt;BR /&gt; OldName,&lt;BR /&gt; NewName&lt;BR /&gt;FROM ..CustomerChangeMap.xlsx;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//------------------------&lt;/P&gt;&lt;P&gt;// loading new data, in your case Dec2014&lt;BR /&gt;Facttable:&lt;BR /&gt;LOAD &lt;BR /&gt;&amp;nbsp; autonumberhash128(Year &amp;amp; Month &amp;amp; Customer) as %Key,&amp;nbsp;&amp;nbsp; // autonumber to keep key small&lt;BR /&gt;&amp;nbsp; Year, &lt;BR /&gt;&amp;nbsp; Month, &lt;BR /&gt;&amp;nbsp; Customer,&lt;BR /&gt;&amp;nbsp; [Cost amount]&lt;BR /&gt;FROM ..NewData.xlsx;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// Loading QVD, converting Customer name; load will be non-optimized because of functions&lt;BR /&gt;PrevData:&lt;BR /&gt;LOAD &lt;BR /&gt;&amp;nbsp; autonumberhash128(Year &amp;amp; Month &amp;amp; applymap('CustomerChangeMap',Customer)) as %QVDKey,&lt;BR /&gt;&amp;nbsp; Year,&lt;BR /&gt;&amp;nbsp; Month,&lt;BR /&gt;&amp;nbsp; applymap('CustomerChangeMap',Customer) as Customer&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // changing Customer name&lt;BR /&gt;&amp;nbsp; [Cost amount]&lt;BR /&gt;FROM ..Extract_Facts.qvd (qvd);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// adding QVD data to facts except if the key exists in new data&lt;BR /&gt;CONCATENATE (Facttable) LOAD&lt;BR /&gt;&amp;nbsp; %QVDKey as %Key,&lt;BR /&gt;&amp;nbsp; Year, &lt;BR /&gt;&amp;nbsp; Month, &lt;BR /&gt;&amp;nbsp; Customer,&lt;BR /&gt;&amp;nbsp; [Cost amount]&lt;BR /&gt;RESIDENT PrevData&lt;BR /&gt;WHERE not exists(%Key, %QVDKey);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP TABLE PrevData;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;STORE Facttable into Extract_Facts.qvd;&lt;/P&gt;&lt;P&gt;____________________________________________&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope I didn't miss anything essential...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 04 Mar 2015 16:14:16 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-03-04T16:14:16Z</dc:date>
    <item>
      <title>INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821755#M2907</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear ladies and gentlemen,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am having an issue with my incremental load script, and I am not 100% sure how I can solve this issue in Qlikview,&lt;/P&gt;&lt;P&gt;My first file nov2014 includes data from 2013-01-01 and my second file dec2014 includes partly updated data since 2013-01-01 including an additional month of dec2014 that the previous file does not have.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Some content from nov2014 file:&lt;/P&gt;&lt;P&gt;Year&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Month&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Customer&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cost Amount&lt;/P&gt;&lt;P&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 100&lt;/P&gt;&lt;P&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 50&lt;/P&gt;&lt;P&gt;2014&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 90&lt;/P&gt;&lt;P&gt;2014&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 80&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATED and NEW content from dec2014 file:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Year&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Month&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Customer&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cost Amount&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ABC&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 100&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Here we have a new customer name&lt;/P&gt;&lt;P&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 45&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Here we have a different cost amount&lt;/P&gt;&lt;P&gt;2014&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 90&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Same as in nov2014&lt;/P&gt;&lt;P&gt;2014&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 80&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // &lt;SPAN style="font-size: 13.3333330154419px;"&gt;Same as in nov2014&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;2014&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 12&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EF&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 70&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // NEW rows&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;2014&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 12&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; GH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 60&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // NEW rows&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Data file analysis:&lt;/P&gt;&lt;P&gt;There are NO unique row identifier or primarykey. This is basically all we have.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My question:&lt;/P&gt;&lt;P&gt;How can I create an INCREMENTAL LOAD in Qlikview that UPDATES rows as well as ADD new rows into a .QVD file.&lt;/P&gt;&lt;P&gt;I am not sure if this can be done, even if I use a composite key using [Year &amp;amp;'-'&amp;amp; Month as %YearMonthKey] when concatenating the 2 files(tables).&lt;/P&gt;&lt;P&gt;Adding new additional rows works great using the WHERE NOT EXISTS (&lt;SPAN style="font-size: 13.3333330154419px;"&gt;%YearMonthKey), but what about updating rows?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;We only have Year and Month columns that are constant, but since the Customer name can change as well, I can not use it in the Composite key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do any of you have any good ideas or some advice on how I could do this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Maybe I could use a composite key that includes the Customer name: [&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Year &amp;amp;'-'&amp;amp; Month &lt;SPAN style="font-size: 13.3333330154419px;"&gt;&amp;amp;'-'&amp;amp; Customer as %Key] and update the [Cost Amount] field first, and then use a different composite key to update the name of the customers. I am not sure!&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Is it even possible to do what I want?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Appreciate all your help and advice!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sincerely,&lt;BR /&gt;Daniel Wardzynski&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jul 2025 17:59:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821755#M2907</guid>
      <dc:creator>wardzynski</dc:creator>
      <dc:date>2025-07-22T17:59:49Z</dc:date>
    </item>
    <item>
      <title>Re: INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821756#M2908</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;The point of an incremental load is to retrieve only new and/or changed records from the database to Qlikview. Normally this is done with a monotonically increasing key or date, or a date created or last updated field in the database. Then a simple where clause in your SQL query will fetch only the relevant data from the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you need to create a key and use WHERE EXISTS in Qlikview, then you are first fetching all the data from the database and then filtering it in Qlikview, which kind of negates the benefits of an incremental load.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So you will need to pass something into the SQL SELECT that allows filtering there.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Mar 2015 14:23:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821756#M2908</guid>
      <dc:creator>jonathandienst</dc:creator>
      <dc:date>2015-03-03T14:23:17Z</dc:date>
    </item>
    <item>
      <title>Re: INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821757#M2909</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for your reply Jonathan.&lt;/P&gt;&lt;P&gt;[Where Not Exists()] is a vital part of an Incremental load (Insert and Update) scenario.&lt;/P&gt;&lt;P&gt;Take a look at this thread: &lt;A href="http://www.learnallbi.com/incremental-load-in-qlikview-part2/" title="http://www.learnallbi.com/incremental-load-in-qlikview-part2/"&gt;Incremental Load in QlikView – Part2 | Learn QlikView&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It seems that if I have 4 rows in my nov2014 file that share the same YEAR and MONTH as 2 rows in my dec2014 file. For instance:&lt;/P&gt;&lt;P&gt;nov2014 file contains:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;Year&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Month&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Customer&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cost Amount&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 100&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 200&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 300&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;dec2014 file contains:&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;Year&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Month&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Customer&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cost Amount&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 999&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;Then the outcome is only:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Year&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Month&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Customer&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cost Amount&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;2013&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 999&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;This happens when I am using WHERE NOT EXISTs (%YearMonthKey); &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;// Year &amp;amp;'-'&amp;amp; Month &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;amp;'-'&amp;amp; as &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;%YearMonthKey &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;So it basically deletes and replaces ALL OLD rows with the same year and month, with NEW rows with the same year and month, even if I have fewer rows. At the same time it adds all new rows for the new month: december 2014, that did not exist in the previous file: nov2014.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Am I on the right track folks? Is this correct?&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;In that case, I can use this kind of logic, and later figure out a better way to update the [Customer] names in order to concatenate different customer names into 1 name.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.3333330154419px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Mar 2015 15:38:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821757#M2909</guid>
      <dc:creator>wardzynski</dc:creator>
      <dc:date>2015-03-03T15:38:32Z</dc:date>
    </item>
    <item>
      <title>Re: INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821758#M2910</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is apparently in the fact that the customer name can be changed.&amp;nbsp; If not for your comment, it is impossible to tell that AB and ABC is the same customer.&amp;nbsp; But you should be able to know it somehow to add this comment.&amp;nbsp; Is there something like "customer&amp;nbsp; id" that never changes?&amp;nbsp; If yes, you could've mapped to it and use in the key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Michael&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Mar 2015 15:38:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821758#M2910</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-03T15:38:41Z</dc:date>
    </item>
    <item>
      <title>Re: INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821759#M2911</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Michael,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unfortunately there are no unique identifiers in these files, so no unique customer number. What I am thinking is creating a change-map that maps all new and changed Customer names that are connected to a particular customer name, that way we can maintain consistency with the customer names.&lt;/P&gt;&lt;P&gt;What do you think about this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What about my &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;WHERE NOT EXISTs incremental load logics above. I&lt;/SPAN&gt;s my thinking regarding the actual row updates correct that I wrote above?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Mar 2015 16:01:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821759#M2911</guid>
      <dc:creator>wardzynski</dc:creator>
      <dc:date>2015-03-03T16:01:08Z</dc:date>
    </item>
    <item>
      <title>Re: INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821760#M2912</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The change map sounds good, in fact you're making customer name a reliable identifier,&amp;nbsp; So, the key combining Year, Month, and Customer is a way to go.&lt;/P&gt;&lt;P&gt;Yes, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.33px;"&gt;WHERE NOT EXISTS is good to use here.&amp;nbsp; Typically I create the key in the first table only, e.g.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.33px;"&gt;Year &amp;amp; Month &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.33px;"&gt;&amp;amp;Customer as &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.33px;"&gt;%Key &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.33px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;And when loading the second table, use this:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13.33px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;WHERE NOT EXISTS (&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.33px;"&gt;%Key, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.33px;"&gt;Year &amp;amp; Month &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.33px;"&gt;&amp;amp;Customer&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Mar 2015 16:25:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821760#M2912</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-03T16:25:53Z</dc:date>
    </item>
    <item>
      <title>Re: INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821761#M2913</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Micheal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your reply and clarification. With the code below I am basically replacing all the OLD rows that have the &lt;SPAN style="font-size: 13.3333330154419px;"&gt;Year &amp;amp;'-'&amp;amp; Month as %Key, with NEW rows, even if there is only 1 new row, it completely replaces all OLD rows with the same %Key (deletes all the old rows and replaces with 1 new), and this is exactly what I want. Then it also adds(concatenates) NEW rows that DOES NOT exist (do not have the same %Key) since before.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Do you agree with me Micheal?&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;With the Customer map we discussed I should do it before I run the Incremental load, am I correct?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is my code in 2 parts, first the initial load and then the incremental load:&lt;/P&gt;&lt;P&gt;-----------------------------------------------&lt;/P&gt;&lt;P&gt;// PART 1&lt;/P&gt;&lt;P&gt;// Initial Load&lt;/P&gt;&lt;P&gt;Facttable:&lt;/P&gt;&lt;P&gt;LOAD &lt;/P&gt;&lt;P&gt;&amp;nbsp; Year &amp;amp;'-'&amp;amp; Month as %Key,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Year, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Month, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Customer,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Cost amount]&lt;/P&gt;&lt;P&gt;FROM ..2014nov.xlsx&lt;/P&gt;&lt;P&gt;STORE Facttable into Extract_Facts.qvd;&lt;/P&gt;&lt;P&gt;DROP Table facttable;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;/ PART 2&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;// Incremental Load&lt;/P&gt;&lt;P&gt;Facttable:&lt;/P&gt;&lt;P&gt;LOAD &lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp; Year &amp;amp;'-'&amp;amp; Month as %Key,&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp; Year, &lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp;&amp;nbsp; Month, &lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp;&amp;nbsp; Customer,&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Cost amount]&lt;/P&gt;&lt;P&gt;FROM ..&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;2014dec.xlsx&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Concatenate&lt;/P&gt;&lt;P&gt;Facttable:&lt;/P&gt;&lt;P&gt;LOAD &lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp; %Key,&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp; Year, &lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp;&amp;nbsp; Month, &lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp;&amp;nbsp; Customer,&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Cost amount]&lt;/P&gt;&lt;P&gt;FROM ..&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;Extract_Facts.qvd (qvd)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;WHERE NOT EXISTs (%Key);&lt;/P&gt;&lt;P&gt;STORE Facttable into Extract_Facts.qvd;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Mar 2015 09:11:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821761#M2913</guid>
      <dc:creator>wardzynski</dc:creator>
      <dc:date>2015-03-04T09:11:58Z</dc:date>
    </item>
    <item>
      <title>Re: INCREMENTAL LOAD with UPDATE and NEW rows without a unique identifier</title>
      <link>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821762#M2914</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Close...&amp;nbsp; Assuming you have QVD with the previous data, and a file with the additional/changed data, here is what I see:&lt;BR /&gt;______________________________________________&lt;BR /&gt;CustomerChangeMap:&lt;BR /&gt;MAPPING LOAD DISTINCT&lt;BR /&gt; OldName,&lt;BR /&gt; NewName&lt;BR /&gt;FROM ..CustomerChangeMap.xlsx;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//------------------------&lt;/P&gt;&lt;P&gt;// loading new data, in your case Dec2014&lt;BR /&gt;Facttable:&lt;BR /&gt;LOAD &lt;BR /&gt;&amp;nbsp; autonumberhash128(Year &amp;amp; Month &amp;amp; Customer) as %Key,&amp;nbsp;&amp;nbsp; // autonumber to keep key small&lt;BR /&gt;&amp;nbsp; Year, &lt;BR /&gt;&amp;nbsp; Month, &lt;BR /&gt;&amp;nbsp; Customer,&lt;BR /&gt;&amp;nbsp; [Cost amount]&lt;BR /&gt;FROM ..NewData.xlsx;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// Loading QVD, converting Customer name; load will be non-optimized because of functions&lt;BR /&gt;PrevData:&lt;BR /&gt;LOAD &lt;BR /&gt;&amp;nbsp; autonumberhash128(Year &amp;amp; Month &amp;amp; applymap('CustomerChangeMap',Customer)) as %QVDKey,&lt;BR /&gt;&amp;nbsp; Year,&lt;BR /&gt;&amp;nbsp; Month,&lt;BR /&gt;&amp;nbsp; applymap('CustomerChangeMap',Customer) as Customer&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // changing Customer name&lt;BR /&gt;&amp;nbsp; [Cost amount]&lt;BR /&gt;FROM ..Extract_Facts.qvd (qvd);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// adding QVD data to facts except if the key exists in new data&lt;BR /&gt;CONCATENATE (Facttable) LOAD&lt;BR /&gt;&amp;nbsp; %QVDKey as %Key,&lt;BR /&gt;&amp;nbsp; Year, &lt;BR /&gt;&amp;nbsp; Month, &lt;BR /&gt;&amp;nbsp; Customer,&lt;BR /&gt;&amp;nbsp; [Cost amount]&lt;BR /&gt;RESIDENT PrevData&lt;BR /&gt;WHERE not exists(%Key, %QVDKey);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP TABLE PrevData;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;STORE Facttable into Extract_Facts.qvd;&lt;/P&gt;&lt;P&gt;____________________________________________&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope I didn't miss anything essential...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Mar 2015 16:14:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Archived-Groups/INCREMENTAL-LOAD-with-UPDATE-and-NEW-rows-without-a-unique/m-p/821762#M2914</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-04T16:14:16Z</dc:date>
    </item>
  </channel>
</rss>

