2012-03-22 41 views
0

我有一个输入csv文件,列的position_Id,Asofdate等必须加载到登台表中。在我的表中,列Position_Id,AsofDate是主键。我们收到了这个输入文件2个小时。对于Exmaple,我们在今天上午10点收到了File,并将这些文件加载​​到表格中。再过2个小时后,我们再次收到另一个文件,其中包含与我们在2小时前收回的文件相同的数据,并将数据加载到表格中。SSIS中的增量负载

Now my table contains the data of the file that we recived at 10 Am and 12 pm. At 12:10 pm we received modified input file with different data inside it. Now, my actual requirement is, before the latest input file (12:10 Pm) data is loaded int table, it has to see that only new and updated data has to be loaded into the table. 

回答

2

你有没有听说过这个词Upsert的?以下是如何插入(插入新记录和更新现有记录)的示例。

  1. This blog post引导您使用数据流中的查找Upserting。
  2. stackoverflow answer提供了解释和设置合并的链接。