且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

SSIS-插入新行,更新行

更新时间:2022-03-11 07:09:24

那些链接是那里***的.菲尔(Phil)和杰米(Jamie)在这个问题上知识渊博.您唯一真正可行的选择是加载整个表并使用T-SQL的MERGE命令找出差异.

Those links are the best out there. Phil and Jamie are very knowledgeable on the subject. Your only other real alternative is to load the whole table and use T-SQL's MERGE command to figure out differences.

Jamie Thomson的帖子具有三个输出,这些输出以Union Alls结尾,在您的最终数据库上并没有真正起作用".明确地说,您可以舍弃这些输出之一-因为它是无变化"输出(标记为年龄保持不变"的输出).标记为新客户"的一个可能会路由到OLE DB目标中.标记为年龄已更改"的一个是您要路由到OLE DB命令转换的那个.

Jamie Thomson's post has three outputs that end in Union Alls that don't really "do work" on your end database. To be clear, one of those outputs you can discard - because it's the "no change" output (the one that's labeled "Age has stayed the same"). The one labeled "New Customers" is one you would probably route into an OLE DB Destination. The one labeled "Age has changed" is the one you'd route into an OLE DB Command transform.

现在,OLE DB Command转换不能这么快地工作.有很多方法可以解决这种问题,但是快速搜索应该可以为您解决该问题.

Now, the OLE DB Command transform doesn't work that fast. There are ways around that slowness, but a quick search should fix that problem for you.