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

Support inserting into Delta Lake table having invariants #16136

Merged
merged 2 commits into from
Mar 9, 2023

Conversation

ebyhr
Copy link
Member

@ebyhr ebyhr commented Feb 16, 2023

Description

Support inserting into Delta Lake table having invariants

Release notes

(x) Release notes are required, with the following suggested text:

# Delta Lake
* Add support for inserting into tables having [column invariants](https://github.com/delta-io/delta/blob/master/PROTOCOL.md#column-invariants). ({issue}`16136`)

@ebyhr ebyhr added the delta-lake Delta Lake connector label Feb 16, 2023
@ebyhr ebyhr self-assigned this Feb 16, 2023
@cla-bot cla-bot bot added the cla-signed label Feb 16, 2023
@ebyhr ebyhr force-pushed the ebi/delta-invariant branch 2 times, most recently from c5a6d11 to 8a04f92 Compare February 16, 2023 22:20
@ebyhr ebyhr force-pushed the ebi/delta-invariant branch from 8a04f92 to 90536cd Compare February 26, 2023 23:11
@ebyhr
Copy link
Member Author

ebyhr commented Feb 26, 2023

/test-with-secrets sha=90536cded9528a3748e25a2a8318833482b68a62

@ebyhr ebyhr requested a review from findepi March 8, 2023 10:10
Comment on lines -183 to -184
assertThatThrownBy(() -> query("INSERT INTO invariants VALUES(2)"))
.hasMessageContaining("Inserts are not supported for tables with delta invariants");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How was that working? Shouldn't it be failing with table not found?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if I understand the question correctly. The previous table name was invariants having column invariants and it existed, so it shouldn't throw table not found in my opinion. I renamed to a new table name with random suffix to avoid modifying shared tables.

@ebyhr ebyhr force-pushed the ebi/delta-invariant branch from 90536cd to c22bab7 Compare March 8, 2023 22:32
@ebyhr ebyhr merged commit defd6ee into trinodb:master Mar 9, 2023
@ebyhr ebyhr deleted the ebi/delta-invariant branch March 9, 2023 05:56
@ebyhr ebyhr mentioned this pull request Mar 9, 2023
@github-actions github-actions bot added this to the 411 milestone Mar 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed delta-lake Delta Lake connector
Development

Successfully merging this pull request may close these issues.

3 participants