deniskuzZ commented on code in PR #6074:
URL: https://github.com/apache/hive/pull/6074#discussion_r2358456360
##########
ql/src/java/org/apache/hadoop/hive/ql/ddl/table/constraint/ConstraintsUtils.java:
##########
@@ -243,7 +251,10 @@ private static List<ConstraintInfo>
generateConstraintInfos(ASTNode child, List<
rely = false;
} else if (childType == HiveParser.TOK_DEFAULT_VALUE) {
// try to get default value only if this is DEFAULT constraint
- checkOrDefaultValue = getDefaultValue(grandChild, typeChildForDefault,
tokenRewriteStream);
+ colTypeInfo =
TypeInfoUtils.getTypeInfoFromTypeString(BaseSemanticAnalyzer.getTypeStringFromAST(typeChildForDefault));
+ Object[] defaultValueTypeAndValue = getDefaultValue(grandChild,
tokenRewriteStream);
+ checkOrDefaultValue = (String) defaultValueTypeAndValue[1];
+ defaultValueType = (TypeInfo) defaultValueTypeAndValue[0];
Review Comment:
minor: can we rearrange the initialization: first type and then value, so
that index access is incremental
--
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]