You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@hive.apache.org by "SourabhBadhya (via GitHub)" <gi...@apache.org> on 2023/08/21 07:01:21 UTC
[GitHub] [hive] SourabhBadhya commented on a diff in pull request #4571: HIVE-27627: Iceberg: Insert into/overwrite partition support
SourabhBadhya commented on code in PR #4571:
URL: https://github.com/apache/hive/pull/4571#discussion_r1299688049
##########
ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java:
##########
@@ -7493,9 +7507,17 @@ protected Operator genFileSinkPlan(String dest, QB qb, Operator input)
// Add NOT NULL constraint check
input = genConstraintsPlan(dest, qb, input);
+ if (destinationTable.getStorageHandler() != null && destinationTable.getStorageHandler().alwaysUnpartitioned()) {
+ partSpec = qbm.getPartSpecForAlias(dest);
+ }
if (!qb.getIsQuery()) {
- input = genConversionSelectOperator(dest, qb, input, destinationTable.getDeserializer(), dpCtx, null, destinationTable);
+ if (!updating(dest) && !deleting(dest)) {
+ input = genConversionSelectOperatorByAddPartition(dest, qb, input,
+ destinationTable.getDeserializer(), destinationTable, partSpec);
+ }
+ input = genConversionSelectOperator(dest, qb, input, destinationTable.getDeserializer(), dpCtx, null,
+ destinationTable);
Review Comment:
@kasakrisz The idea is to isolate the addition of partition column into the operator with other set of conditions.
--
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: gitbox-unsubscribe@hive.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org