Open nlu90 opened 3 years ago
@nlu90 In upsert-pulsar, the key.fields
and key.fields-prefix
options will no longer be used, you need to use the PRIMARY KEY
statement
CREATE TABLE some_table (
`order_id` STRING,
`transaction_time` STRING,
PRIMARY KEY (order_id) NOT ENFORCED
) WITH (
'connector' = 'upsert-pulsar',
'admin-url' = 'http://localhost:55092',
'service-url' = 'pulsar://localhost:55093',
'topic' = 'persistent://public/default/topic54188168',
'value.format' = 'avro',
'key.format' = 'raw'
)
INSERT INTO some_table
VALUES
('1', 'name 1'),
('2', 'name 2'),
('3', 'name 3'),
('2', 'name 2')
Another issue, it seems that PulsarDynamicTableFactory
was created, suggest to recheck and test it. I was unable to reproduce the problem.
Describe the bug Fail to create correct table sink when inserting into an upsert table
To Reproduce for table:
and query:
get the following error message:
Seems default options are used and it's calling the
PulsarDynamicTableFactory
instead ofUpsertPulsarDynamicTableFactory
to create the table sinkExpected behavior
UpsertPulsarDynamicTableFactory
should be used to create table sink.