yuqi1129 commented on code in PR #10366:
URL: https://github.com/apache/gravitino/pull/10366#discussion_r2918488613
##########
catalogs-contrib/catalog-jdbc-hologres/src/main/java/org/apache/gravitino/catalog/hologres/operation/HologresTableOperations.java:
##########
@@ -531,9 +535,15 @@ private String deleteColumnFieldDefinition(
throw new IllegalArgumentException("Delete column does not exist: " +
col);
}
}
+ // Hologres requires enabling the GUC parameter before dropping a column.
+ // Reference:
https://help.aliyun.com/zh/hologres/developer-reference/alter-table
return String.format(
- "%s%s DROP COLUMN %s;",
- ALTER_TABLE, quoteIdentifier(table.name()),
quoteIdentifier(deleteColumn.fieldName()[0]));
+ "%s%s%s%s DROP COLUMN %s;",
+ HOLOGRES_ENABLE_DROP_COLUMN_GUC,
+ NEW_LINE,
Review Comment:
I think there is no need to add `NEW_LINE` here. as SQL like `sentence one;
sentence two; ....; ...` seems to be more straight forward.
--
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]