You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
create table hive.default.commontable (id bigint);
create table iceberg.default.commontable (id bigint);
The second query fails with the exception:
[2022-01-03 06:43:31] [84148224] Query failed (#20220103_054331_00040_cc26e): Not an Iceberg table: default.commontable
This message is rather misleading and should be changed with a meaningful message for the end user pointing out that a table with the same name and schema already exists in the hive metastore.
The issue occurs in io.trino.plugin.iceberg.catalog.AbstractMetastoreTableOperations#refresh method
if (!isIcebergTable(table)) {
throw new UnknownTableTypeException(getSchemaTableName());
}
However, due to the fact that the connectors hive and iceberg share the same hive metastore it is rather difficult to give a meaningful message in this case.
Executing the following statements
create table hive.default.commontable (id bigint);
create table hive.default.commontable (id bigint);
leads to the following error (as expected):
Query failed (#20220103_143437_00019_y848r): line 1:1: Table 'hive.default.commontable' already exists
findepi
changed the title
Misleading exception when trying to create a table which already exists in the hive metastore
Misleading exception when trying to create Iceberg table if Hive table with same name already exists
Feb 1, 2022
The second query fails with the exception:
This message is rather misleading and should be changed with a meaningful message for the end user pointing out that a table with the same name and schema already exists in the hive metastore.
The issue occurs in
io.trino.plugin.iceberg.catalog.AbstractMetastoreTableOperations#refresh
methodHowever, due to the fact that the connectors
hive
andiceberg
share the same hive metastore it is rather difficult to give a meaningful message in this case.Executing the following statements
leads to the following error (as expected):
Related issues:
#8693
The text was updated successfully, but these errors were encountered: