Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Primary key not passed to connector node #8651

Closed
wenym1 opened this issue Mar 20, 2023 · 0 comments · Fixed by #8660
Closed

Primary key not passed to connector node #8651

wenym1 opened this issue Mar 20, 2023 · 0 comments · Fixed by #8660
Assignees
Labels
type/bug Something isn't working
Milestone

Comments

@wenym1
Copy link
Contributor

wenym1 commented Mar 20, 2023

Describe the bug

I was trying to create an upsert iceberg sink from an upstream table created with schema

CREATE TABLE s1 (
    seq_id bigint, 
    user_id bigint,
    user_name varchar)                      
WITH (             
    connector = 'datagen',
    ...
);

CREATE TABLE s1 (seq_id bigint, user_id bigint,
  usercreate sink s1_sink from s1
with (              
    connector = 'iceberg',
    type='upsert',
    primary_key = 'seq_id',
    warehouse.path = 's3a://yiming-test1/iceberg',
    s3.endpoint = 'https://s3.ap-southeast-1.amazonaws.com',
    s3.access.key = '...',
    s3.secret.key = '...',
    database.name='dev', = 'random',
    table.name='table'
);

but it fails with an error try to insert a duplicated primary key in the connector node log.

I added some other log, and figure out that the TableSchema class has an empty primaryKeys.

table schema: TableSchema{columnNames=[seq_id, user_id, user_name], columns={user_id=INT64, user_name=VARCHAR, seq_id=INT64}, columnIndices={user_id=1, user_name=2, seq_id=0}, primaryKeys=[]}

To Reproduce

No response

Expected behavior

No response

Additional context

No response

@wenym1 wenym1 added the type/bug Something isn't working label Mar 20, 2023
@github-actions github-actions bot added this to the release-0.19 milestone Mar 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants