Gustavo de Morais created FLINK-39708:
-----------------------------------------

             Summary: Support TO_CHANGELOG retract/upsert stream -> upsert 
stream with set semantics
                 Key: FLINK-39708
                 URL: https://issues.apache.org/jira/browse/FLINK-39708
             Project: Flink
          Issue Type: Sub-task
          Components: Table SQL / API
            Reporter: Gustavo de Morais
            Assignee: Gustavo de Morais


Extend {{TO_CHANGELOG}} so that, when called with {{PARTITION BY}} on an upsert 
or retract input, it can emit an upsert stream instead of always forcing 
retract semantics.

The output shape is controlled by {{{}op_mapping{}}}:
 * {{op_mapping}} omits {{UPDATE_BEFORE}} → output is an upsert stream; the 
planner skips the {{ChangelogNormalize}} step that would otherwise materialize 
{{UPDATE_BEFORE}} rows.
 * {{op_mapping}} omits {{DELETE}} → the planner skips the full-{{{}DELETE{}}} 
materialization step in {{ChangelogNormalize}} (key-only deletes flow through, 
matching sources like Flink's {{upsert-kafka}} connector).
 * {{op_mapping}} includes both → retract as default



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

Reply via email to