When using FineDataLink to process data, you may wonder:
What is Physical Deletion? What is Logical Deletion?
What is the difference between Physical Deletion and Logical Deletion?
This document introduces these two deletion methods.
1. The following scenarios (where neither the source table nor the target table is a Jodoo form) can be implemented by using the Data Synchronization node:
You are not advised to use Logical deletion in these scenarios.
There is no identifier field, and you have obtained data through filtering. You want to insert the obtained data into the target table, update data in the target table using the obtained data, or remove data corresponding to the obtained data from the target table. (Only one operation type can be selected when there is no identifier field.)
There is an identifier field and identifier values, and you need to implement data insertion/update/deletion.
For details about using the Data Synchronization node to implement the operations, see Adding/Modifying/Deleting Data Based on the Identifier Field.
2. You can implement data insertion/deletion/update by using the combination of the Data Comparison operator and DB Table Output operator or the Data Comparison operator and Jodoo Output operator.
When you use the combination of the Data Comparison operator and DB Table Output operator or the Data Comparison operator and Jodoo Output operator to implement data deletion:
For details, see Data Comparison Example.
Physical Deletion: If the data is deleted from the source table, the corresponding data will be deleted from the target table.
Logical Deletion: Mark data as deleted using an identifier column without actually deleting it from the target table.
By default, the field fdl_comparison_type is added to the target table as an identifier column, with its value modified to Removed, indicating that the data is deleted.
For details about examples of Logical Deletion, see Example One: Logical Deletion.
When configuring Target Selection during the creation of a pipeline task, you can select Physical Deletion at Target End/Logical Deletion at Target End as Data Deletion Strategy, as shown in the following figure.
Physical Deletion at Target End: If the data is deleted from the source table, the corresponding data will also be deleted from the target table.
Logical Deletion at Target End: Add a boolean field named _fdl_marked_deleted (whose value defaults to false) to the target table to record the deletion status of data in the source table without actually deleting data in the target table. If a data record is deleted from the source table, the system will not physically delete the corresponding record in the target table after synchronization. Instead, it will change the _fdl_marked_deleted value of this record to true.
滑鼠選中內容,快速回饋問題
滑鼠選中存在疑惑的內容,即可快速回饋問題,我們將會跟進處理。
不再提示
10s後關閉
Submitted successfully
Network busy