Hi srikanth~

The Flink SQL update-mode is inferred from the target table type.
For now, there are three StreamTableSink type, `AppendStreamTableSink` 
`UpsertStreamTableSink` and `RetractStreamTableSink`. 
If the target table is a type of Kafka which implments AppendStreamTableSink, 
the update-mode will be append only. 
So if you want enable retract-mode you may need to insert into one kind of 
RetractStreamTableSink.
Hope it helps you ~



Best,
Terry Wang



> 在 2019年9月26日,下午2:50,srikanth flink <flink.d...@gmail.com> 写道:
> 
> How could I configure environment file for Flink SQL, update-mode: retract?
> 
> I have this for append:
> properties:         
>         - key: zookeeper.connect
>           value: localhost:2181
>         - key: bootstrap.servers
>           value: localhost:9092
>         - key: group.id <http://group.id/>
>           value: reconMultiAttempFail
>     format:
>       type: json
>       fail-on-missing-field: false
>       json-schema: >
>         {
>           type: 'object',
>           properties: {
>             'a': {
>                type: 'string'
>             },
>             'b': {
>                type: 'string'
>             },
>             'cnt': {
>                type: 'string'
>             }
>           }
>         }
>       derive-schema: false
> 
>     schema:
>       - name: 'a'
>         type: VARCHAR
>      - name: 'b'
>         type: VARCHAR
>       - name: 'cnt'
>         type: BIGINT
> 
> Couldn't find any document for the same. 
> 
> someone help me with the syntax.
> 
> Thanks
> Srikanth
> 

Reply via email to