Anurag Mantripragada created SPARK-58007:
--------------------------------------------

             Summary: Support dynamic table options for MERGE
                 Key: SPARK-58007
                 URL: https://issues.apache.org/jira/browse/SPARK-58007
             Project: Spark
          Issue Type: Improvement
          Components: SQL
    Affects Versions: 5.0.0
            Reporter: Anurag Mantripragada


Spark supports a per-statement `WITH (key = value)` options clause on `SELECT` 
(SPARK-36680), `INSERT` (SPARK-49098), and `UPDATE` (SPARK-57681). These 
options are passed to DataSource V2 connectors so a single statement can tune 
how the source reads or writes.

`MERGE` does not support this yet. This ticket adds the `WITH (...)` clause to 
`MERGE`, for both the target and the source:

```sql
MERGE INTO target_table WITH (`write.split-size` = 10) AS t
USING source_table WITH (`split-size` = 5) AS s
ON t.id = s.id
WHEN MATCHED THEN UPDATE SET ...
WHEN NOT MATCHED THEN INSERT ...
```




--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to