Astralidea commented on a change in pull request #4445:
URL: https://github.com/apache/incubator-doris/pull/4445#discussion_r476372131
##########
File path:
fe/fe-core/src/main/java/org/apache/doris/analysis/BinaryPredicate.java
##########
@@ -307,6 +307,16 @@ private Type getCmpType() {
return Type.LARGEINT;
}
+ // Try parse varchar to bigint
+ if (t1 == PrimitiveType.BIGINT && t2 == PrimitiveType.VARCHAR) {
Review comment:
> Because we have `NormalizeBinaryPredicatesRule`. You could only
consider slot in left and string Literal in right
但是我试了一下,如果我注释掉代码后,如果SQL这么写,还是转成Double了,虽然很少有人这么写SQL。
explain select count()
from app_rt_flow_poi_intent_uv_price_v2
where '20200730'=datekey
我看了一下,在`analyzeAndGenerateQueryPlan`是先parsedStmt.analyze再parsedStmt.rewriteExprs这个cast是在analyze里完成的。这块是不是把rewrite提前面不太好提-
-。
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]