starocean999 commented on code in PR #24965:
URL: https://github.com/apache/doris/pull/24965#discussion_r1367041405
##########
fe/fe-core/src/main/java/org/apache/doris/analysis/BinaryPredicate.java:
##########
@@ -411,6 +420,19 @@ private Type getCmpType() throws AnalysisException {
}
}
+ if (canCompareIP(getChild(0).getType().getPrimitiveType(),
getChild(1).getType().getPrimitiveType())) {
+ if ((getChild(0).getType().isIP() && getChild(1) instanceof
StringLiteral)
+ || (getChild(1).getType().isIP() && getChild(0) instanceof
StringLiteral)
+ || (getChild(0).getType().isIP() &&
getChild(1).getType().isIP())) {
+ if (getChild(0).getType().isIPv4() ||
getChild(1).getType().isIPv4()) {
Review Comment:
if IPV4 cmp IPV6, the getCmpType will return IPV4, is this the expected
behavior?
--
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]