<?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: Update/insert the record and maintain the history in SAS Data Management</title>
    <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637801#M19085</link>
    <description>&lt;P&gt;I will get delta records separately and in that there won't be any fields like&amp;nbsp; 'Act_Ind' and 'valid_from' and 'valid_to' . It is our duty to insert/update the changes to the main master file and change the 'Act_Ind' and 'valid_from' and 'valid_to' fields.&lt;/P&gt;</description>
    <pubDate>Mon, 06 Apr 2020 07:56:13 GMT</pubDate>
    <dc:creator>David_Billa</dc:creator>
    <dc:date>2020-04-06T07:56:13Z</dc:date>
    <item>
      <title>Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637658#M19080</link>
      <description>&lt;P&gt;We've a process where clients will update the file (say sales details) when there is a need and they intimate us about the change. So our job is to load those updated records to SQL DB table by maintaing the history.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For the first time while loading the data to SQL we just did a 'proc append' to SQL table after reading the file via data step infile Statement. However this method will not work to track the history in SQL when there is a update in the file.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm not Aware of SCDs as well.&amp;nbsp; We are not using any Primary/foreign key stuff in SQL.I would like to understand how I can tackle the situation to update the history. I tried with 'Proc SQL update' and 'If first. and last.' but it didn't helped either. Appericiate your help here. I'm OK with any approach to implement this exercise.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Assume I've a file like this.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;TABLE border="0" width="576" cellspacing="0" cellpadding="0"&gt;&lt;COLGROUP&gt;&lt;COL span="8" width="72" /&gt;&lt;/COLGROUP&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="72" height="20"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Id&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;&amp;nbsp;Name&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Sales&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Transaction&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Example Values&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Act_Ind&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Valid_From&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Valid_To&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD height="19" align="right"&gt;&lt;FONT color="#000000"&gt;1&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Unit&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;6&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;58001&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Y&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;19000101T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;99991231T235959&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD height="19" align="right"&gt;&lt;FONT color="#000000"&gt;2&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Key&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;6&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;121216&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Y&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;19000101T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;99991231T235959&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD height="19" align="right"&gt;&lt;FONT color="#000000"&gt;3&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Value&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;18&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;820595,2&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Y&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;19000101T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;99991231T235959&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Assume I've received an update to the file like this. If you notice Transaction value has changed for Key from 6 to 8.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;TABLE border="0" width="576" cellspacing="0" cellpadding="0"&gt;&lt;COLGROUP&gt;&lt;COL span="8" width="72" /&gt;&lt;/COLGROUP&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="72px" height="20"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Id&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="70.4px"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;&amp;nbsp;Name&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="47.2px"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Sales&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="64.8px"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Transaction&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="76.8px"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Example Values&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="69.6px"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Act_Ind&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="145.6px"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Valid_From&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="145.6px"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Valid_To&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="72px" height="19" align="right"&gt;&lt;FONT color="#000000"&gt;2&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD width="70.4px"&gt;&lt;FONT color="#000000"&gt;Key&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD width="47.2px"&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD width="64.8px" align="right"&gt;&lt;FONT color="#000000"&gt;8&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD width="76.8px" align="right"&gt;&lt;FONT color="#000000"&gt;121216&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD width="69.6px"&gt;&lt;FONT color="#000000"&gt;Y&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD width="145.6px"&gt;&lt;FONT color="#000000"&gt;20200404T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD width="145.6px"&gt;&lt;FONT color="#000000"&gt;99991231T235959&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So now I want data like this SQL table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;TABLE border="0" width="576" cellspacing="0" cellpadding="0"&gt;&lt;COLGROUP&gt;&lt;COL span="8" width="72" /&gt;&lt;/COLGROUP&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="72" height="20"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Id&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;&amp;nbsp;Name&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Sales&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Transaction&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Example Values&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Act_Ind&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Valid_From&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD width="72"&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;Valid_To&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD height="19" align="right"&gt;&lt;FONT color="#000000"&gt;1&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Unit&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;6&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;58001&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Y&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;19000101T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;99991231T235959&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD height="19" align="right"&gt;&lt;FONT color="#000000"&gt;2&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Key&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;6&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;121216&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;N&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;19000101T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;20200403T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD height="19" align="right"&gt;&lt;FONT color="#000000"&gt;2&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Key&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;8&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;121216&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Y&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;20200404T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;99991231T235959&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD height="19" align="right"&gt;&lt;FONT color="#000000"&gt;3&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Value&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;True&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;18&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD align="right"&gt;&lt;FONT color="#000000"&gt;820595,2&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;Y&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;19000101T000000&lt;/FONT&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;FONT color="#000000"&gt;99991231T235959&lt;/FONT&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;</description>
      <pubDate>Sun, 05 Apr 2020 08:20:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637658#M19080</guid>
      <dc:creator>David_Billa</dc:creator>
      <dc:date>2020-04-05T08:20:17Z</dc:date>
    </item>
    <item>
      <title>Re: Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637683#M19081</link>
      <description>&lt;P&gt;See my answer in your previous thread.&lt;/P&gt;</description>
      <pubDate>Sun, 05 Apr 2020 13:43:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637683#M19081</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2020-04-05T13:43:40Z</dc:date>
    </item>
    <item>
      <title>Re: Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637786#M19082</link>
      <description>&lt;P&gt;That's normal SCD2 loading with - based on your sample data - business key column ID.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2020 04:19:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637786#M19082</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2020-04-06T04:19:32Z</dc:date>
    </item>
    <item>
      <title>Re: Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637787#M19083</link>
      <description>Could you please point me with any examples from any of documents?&lt;BR /&gt;</description>
      <pubDate>Mon, 06 Apr 2020 04:37:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637787#M19083</guid>
      <dc:creator>David_Billa</dc:creator>
      <dc:date>2020-04-06T04:37:08Z</dc:date>
    </item>
    <item>
      <title>Re: Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637792#M19084</link>
      <description>&lt;P&gt;Do you get delta records or full volume records where you have to work out if something changed?&lt;/P&gt;
&lt;P&gt;If delta records: Do you get updates and new inserts together or separately? And if deltas: Do you also get deletes?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In the change records: Do you really get below highlighted columns already from source?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Patrick_0-1586155430522.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/37949iA32FA7FFF4271598/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Patrick_0-1586155430522.png" alt="Patrick_0-1586155430522.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For expired records without a new record (a "delete") but latest record added: What value would Act_ind have? "Y" or "N"?&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2020 07:39:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637792#M19084</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2020-04-06T07:39:00Z</dc:date>
    </item>
    <item>
      <title>Re: Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637801#M19085</link>
      <description>&lt;P&gt;I will get delta records separately and in that there won't be any fields like&amp;nbsp; 'Act_Ind' and 'valid_from' and 'valid_to' . It is our duty to insert/update the changes to the main master file and change the 'Act_Ind' and 'valid_from' and 'valid_to' fields.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2020 07:56:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637801#M19085</guid>
      <dc:creator>David_Billa</dc:creator>
      <dc:date>2020-04-06T07:56:13Z</dc:date>
    </item>
    <item>
      <title>Re: Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637812#M19086</link>
      <description>&lt;P&gt;&lt;SPAN&gt;"&lt;EM&gt;I will get delta records separately&lt;/EM&gt;"&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Details matter so please be specific: &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;- How many delta files per load cycle do you get? - 1, 2 or 3 - if not 3 then what's combined (update, insert, delete)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;-&amp;nbsp;For expired records without a new record (a "delete") but latest record added: What value would Act_ind have? "Y" or "N"?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;- What data volumes are you dealing with? - Both in the target table and in the delta files&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;- Are you using DI Studio?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2020 09:05:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637812#M19086</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2020-04-06T09:05:31Z</dc:date>
    </item>
    <item>
      <title>Re: Update/insert the record and maintain the history</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637916#M19088</link>
      <description>&lt;P&gt;What are the keys for the table?&lt;/P&gt;
&lt;P&gt;So when you get an update does it say whether it is Insert, Delete, or Update?&amp;nbsp; Or do you have to figure that out?&lt;/P&gt;
&lt;P&gt;Once you figure it out then decide what to do in each of the situations.&lt;/P&gt;
&lt;P&gt;For INSERT you should be able to just add a new observation. Make sure to set the from/to timestamps.&lt;/P&gt;
&lt;P&gt;For DELETE you should just update the existing record changing the status and to timestamp.&lt;/P&gt;
&lt;P&gt;For UPDATE you need to convert it to an INSERT and DELETE. See above.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2020 18:40:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Update-insert-the-record-and-maintain-the-history/m-p/637916#M19088</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2020-04-06T18:40:15Z</dc:date>
    </item>
  </channel>
</rss>

