Details
-
Task
-
Resolution: Done
-
Major
-
Mad Hatter
-
DOC-2019-S05-Mar08
-
1
Description
Currently, the MERGE statement uses ON KEY clause:
MERGE INTO target USING source ON KEY <key_expr>
|
WHEN MATCHED THEN <merge_update> or <merge_delete>
|
WHEN NOT MATCHED THEN <merge_insert>
|
The <key_expr> is an expression that maps to a document key of the target keyspace.
This form of MERGE statement will continue to be supported. In addition, the following syntax will also be supported:
MERGE INTO target USING source ON <join_expr>
|
WHEN MATCHED THEN <merge_update> or <merge_delete>
|
WHEN NOT MATCHED THEN <merge_insert>
|
The only major difference is replacement of the ON KEY clause with the ON clause. The join expression is similar to the join condition specification in ANSI JOIN, which can contain any arbitrary expression.