Oracle if updating then

If both are specified, then the order of the clauses is not important.

MERGE allows you to avoid multiple INSERT, UPDATE, and DELETE DML statements by combining the operations into a single statement.

Oracle performs the specified update if the condition of the ON clause is true.

As with any normal update, when the update clause is executed, all update triggers defined on the target table are fired.

ON Clause - The ON clause specifies the condition that the MERGE operation uses to determine whether it updates or inserts.

When the search condition evaluates to true, Oracle updates the row in the target table with corresponding data from the MERGE source.

Leave a Reply