rdblue commented on code in PR #4448:
URL: https://github.com/apache/iceberg/pull/4448#discussion_r863916906
##########
core/src/main/java/org/apache/iceberg/jdbc/JdbcCatalog.java:
##########
@@ -194,7 +194,8 @@ public List<TableIdentifier> listTables(Namespace
namespace) {
public void renameTable(TableIdentifier from, TableIdentifier to) {
int updatedRecords = execute(
err -> {
- if (err instanceof SQLIntegrityConstraintViolationException) {
+ if (err instanceof SQLIntegrityConstraintViolationException ||
+ err.getMessage() != null && err.getMessage().contains("UNIQUE
constraint failed")) {
Review Comment:
We looked into this and there isn't a good way to do it. In
`JdbcTableOperations`, we do the same thing but check for just "constraint
failed". I pasted some links for background in my other comment.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]