Add support for CREATE OR REPLACE TABLE statement#13681
Add support for CREATE OR REPLACE TABLE statement#13681Praveen2112 merged 5 commits intotrinodb:masterfrom
CREATE OR REPLACE TABLE statement#13681Conversation
CREATE OR REPLACE statement
cb2ce4f to
6c8e05c
Compare
CREATE OR REPLACE statementCREATE OR REPLACE TABLE statement
|
Hi, I think this could be unblocked, no? Or am I missing something? |
core/trino-spi/src/main/java/io/trino/spi/connector/ConnectorMetadata.java
Outdated
Show resolved
Hide resolved
core/trino-main/src/main/java/io/trino/execution/CreateTableTask.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/main/java/io/trino/plugin/iceberg/IcebergMetadata.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/main/java/io/trino/plugin/iceberg/IcebergMetadata.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/main/java/io/trino/plugin/iceberg/catalog/AbstractTrinoCatalog.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/main/java/io/trino/plugin/iceberg/catalog/glue/TrinoGlueCatalog.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/main/java/io/trino/plugin/iceberg/IcebergUtil.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/BaseIcebergConnectorTest.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/BaseIcebergConnectorTest.java
Outdated
Show resolved
Hide resolved
plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/BaseIcebergConnectorTest.java
Outdated
Show resolved
Hide resolved
856ab24 to
9958bdd
Compare
9958bdd to
0dc5e09
Compare
|
We are interested in support for |
9404f7c to
0a814fc
Compare
|
@mosabua Can you please take a look at the docs once again. |
2add4d0 to
f72ab79
Compare
|
@mdesmet Build is 🔴 |
f72ab79 to
fe8ca65
Compare
fe8ca65 to
bec23c3
Compare
|
Unrelated CI failure |
There was a problem hiding this comment.
Is this call a left-over?
Why do we need to do the call ? If there is a reasoning behind it, pls document it.
bec23c3 to
1a0eec6
Compare
|
Thanks a lot @mdesmet for working on this amazing feature |
|
@jkylling road is open for Delta Lake PR |
| TrinoFileSystem fileSystem = fileSystemFactory.create(session); | ||
| try { | ||
| if (fileSystem.listFiles(location).hasNext()) { | ||
| if (!replace && fileSystem.listFiles(location).hasNext()) { |
There was a problem hiding this comment.
This should do the check also for replace case, when table handle was not found.
| * @throws TrinoException with {@code ALREADY_EXISTS} if the table already exists and {@param ignoreExisting} is not set | ||
| * @deprecated use {@link #createTable(ConnectorSession session, ConnectorTableMetadata tableMetadata, SaveMode saveMode)} | ||
| */ | ||
| @Deprecated |
There was a problem hiding this comment.
It is time to remove this deprecated method. Can you please follow-up?
There was a problem hiding this comment.
OK. will have a look at this.
Support CREATE OR REPLACE syntax in engine and Iceberg connector.
Description
Fixes #13180
new Feature
Change to core query engine, SPI and connectors
Related issues, pull requests, and links
Documentation
( ) No documentation is needed.
( ) Sufficient documentation is included in this PR.
( ) Documentation PR is available with #prnumber.
( ) Documentation issue #issuenumber is filed, and can be handled later.
Release notes
( ) No release notes entries required.
( ) Release notes entries required with the following suggested text: