Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

SQL Merge

MERGE target_table USING source_table
ON merge_condition
WHEN MATCHED
    THEN update_statement
WHEN NOT MATCHED
    THEN insert_statement
WHEN NOT MATCHED BY SOURCE
    THEN DELETE;
Code language: SQL (Structured Query Language) (sql)
Source by www.sqlservertutorial.net #
 
PREVIOUS NEXT
Tagged: #SQL #Merge
ADD COMMENT
Topic
Name
7+3 =