简体   繁体   中英

Azure Data Factory compare and copy missing rows

I've got 2 tables, and I want to copy only the new rows from table A to table B.

So far I've declared two sources:

  • Table A on sqlserver1
  • Table B on sqlserver2

Now I'm at a loss about how to say only take those rows that are missing in tableB. I've got a compound key. In T-SQL, I'd just use a left join with multiple on statements.

  1. if you want copy data from table a to table with only new rows from table a. you must create data flow like this. I assume that table a is table source and table b is sink (table destination)

从表a到表b的数据流复制

  1. you can add lookup activity as below: for example "PLANT" is unique value from table A or Id_column在此处输入图像描述

  2. you can add lookup activity like this: add column "flag" is using to flag from that Id do you have

在此处输入图像描述

  1. the last is using conditional split like this: 在此处输入图像描述

  2. the last, is you can using sink to Table B...

I hope my explain can help your problem. I'm sory if my english is bad...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM