You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "hongyu guo (Jira)" <ji...@apache.org> on 2023/07/17 02:14:00 UTC
[jira] [Assigned] (CALCITE-5852) Enhance MERGE INTO statement
[ https://issues.apache.org/jira/browse/CALCITE-5852?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
hongyu guo reassigned CALCITE-5852:
-----------------------------------
Assignee: (was: hongyu guo)
> Enhance MERGE INTO statement
> ----------------------------
>
> Key: CALCITE-5852
> URL: https://issues.apache.org/jira/browse/CALCITE-5852
> Project: Calcite
> Issue Type: Improvement
> Reporter: hongyu guo
> Priority: Major
>
> In Calcite, MERGE INTO statement:
> {code:sql}
> merge:
> MERGE INTO tablePrimary [ [ AS ] alias ]
> USING tablePrimary
> ON booleanExpression
> [ WHEN MATCHED THEN UPDATE SET assign [, assign ]* ]
> [ WHEN NOT MATCHED THEN INSERT VALUES '(' value [ , value ]* ')' ]
> {code}
> SQL-2011 and postgres support for <merge when clause>:
> {code:sql}
> -- when matched clause
> WHEN MATCHED [ AND <search condition> ]
> THEN <merge update or delete specification>
> -- when not matched clause
> WHEN NOT MATCHED [ AND <search condition> ]
> THEN <merge insert specification>
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)