The MERGE statement updates the records in a target table to match those in the source table by using update, insert and delete operations with a single statement.

MERGE INTO <target_table> USING <source_table> ON <expression> THEN <procedural_statement>
where:
target_table
is the table in which data is being inserted, updated, deleted.
source_table
is the name of the source table that the target table is being updated to match.
expression
the expression evaluated to determine whether to execute the procedural statement.
procedural_statement
is the procedural statement to be executed when the conditions in the expression are encountered.