CREATE TABLE ODS_PaymentOrdert (
    orderId INT, 
    memberId INT,
        orderAmount DECIMAL(10, 2),
        paymentStatus SMALLINT,
        orderDate VARCHAR,
        payDate VARCHAR,
        paymentIP VARCHAR,
        orderSrc VARCHAR,
        channelType SMALLINT,
        productId SMALLINT,
        amount SMALLINT,
        unit VARCHAR,
        paymentChannel SMALLINT,
        serviceOrderType SMALLINT,
        refundAmount DECIMAL(10, 2),
        proctime as PROCTIME(),
        primary key(orderId) NOT ENFORCED
        ) WITH (
  'connector' = 'kafka',
  'properties.group.id' = 'flink-sql',
  'properties.bootstrap.servers' = 'xx.xx.xx.xxx:9092',
  'topic' = 'ODS_PaymentOrdert',  
  'scan.startup.mode' = 'latest-offset',
  'format' = 'canal-json');          
         

????kafka table option??


????????checkpoint??


------------------ ???????? ------------------
??????:                                                                         
                                               "user-zh"                        
                                                            
<[email protected]&gt;;
????????:&nbsp;2020??9??9??(??????) ????9:46
??????:&nbsp;"user-zh"<[email protected]&gt;;

????:&nbsp;Re: flink-sql????????on kafka??flink table??????select????flink 
table????????????group id??????



Hi

??????????????Kafka table??option ?? ?????? checkpoint????????
????????????????????????????group id,??
?????????????? checkpoint,&nbsp; Flink Kafka consumer ?? enable.auto.commit 
?????????? false????????????????group ??offset?? ???????????????????? group id 
????????????????offset????????????????????????
??????????[1][2]??????????????????????

Best
Leonard

[1] 
https://ci.apache.org/projects/flink/flink-docs-master/zh/dev/connectors/kafka.html#%E9%85%8D%E7%BD%AE-kafka-consumer-%E5%BC%80%E5%A7%8B%E6%B6%88%E8%B4%B9%E7%9A%84%E4%BD%8D%E7%BD%AE
[2] 
https://ci.apache.org/projects/flink/flink-docs-master/zh/dev/connectors/kafka.html#kafka-consumer-%E6%8F%90%E4%BA%A4-offset-%E7%9A%84%E8%A1%8C%E4%B8%BA%E9%85%8D%E7%BD%AE

&gt; ?? 2020??9??9????16:24???????? <[email protected]&gt; ??????
&gt; 
&gt; ??????????????kafka??flink 
table??????????????????????????????????????????select??????????????????????????????????????????????????select????????????group
 id??????????

回复