[fix](DOE) es catalog not working with pipeline,datetimev2, array and esquery (#22046)

This commit is contained in:
qiye
2023-08-01 21:45:16 +08:00
committed by GitHub
parent ff0fda460c
commit b8399148ef
5 changed files with 54 additions and 16 deletions

View File

@ -224,6 +224,11 @@ public final class QueryBuilders {
if (expr == null) {
return null;
}
// esquery functionCallExpr will be rewritten to castExpr in where clause rewriter,
// so we get the functionCallExpr here.
if (expr instanceof CastExpr) {
return toEsDsl(expr.getChild(0), notPushDownList, fieldsContext, builderOptions);
}
// CompoundPredicate, `between` also converted to CompoundPredicate.
if (expr instanceof CompoundPredicate) {
return toCompoundEsDsl(expr, notPushDownList, fieldsContext, builderOptions);