[Deduplication]primary key working differently when running in same session vs running a new session #11241
Open
1 of 3 tasks
Labels
bug
Something isn't working
Apache Iceberg version
1.6.0
Query engine
Flink
Please describe the bug 🐞
i have this code
` StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment();
env.setRuntimeMode(RuntimeExecutionMode.BATCH); // Set to BATCH mode for SQL
// // Step 4: Create the Iceberg table with upsert enabled and a partition column
String createTableSQL = """
CREATE TABLE test_akshay.flink_table_iceberg_12 (
id BIGINT,
data STRING NOT NULL,
year1 INT NOT NULL,
PRIMARY KEY(
id
) NOT ENFORCED) WITH (
'format-version' = '2',
'write.upsert.enabled' = 'true',
'write.merge.mode' = 'copy-on-write',
'write.delete.mode' = 'copy-on-write',
'write.update.mode' = 'copy-on-write',
'partition-spec' = 'year1'
)
""";
// // Step 5: Insert initial mock data with the year value
String insertDataSQL = """
INSERT INTO test_akshay.flink_table_iceberg_12 VALUES
(1, 'data1', 2023),
(2, 'data2', 2023),
(3, 'data3', 2024)
""";
Willingness to contribute
The text was updated successfully, but these errors were encountered: