Lordworms commented on code in PR #8988:
URL: https://github.com/apache/arrow-datafusion/pull/8988#discussion_r1466831986


##########
datafusion/sql/src/expr/mod.rs:
##########
@@ -704,7 +706,20 @@ impl<'a, S: ContextProvider> SqlToRel<'a, S> {
         };
         Ok(Expr::ScalarFunction(ScalarFunction::new(fun, args)))
     }
-
+    fn sql_position_to_expr(
+        &self,
+        substr_expr: SQLExpr,
+        str_expr: SQLExpr,
+        schema: &DFSchema,
+        planner_context: &mut PlannerContext,
+    ) -> Result<Expr> {
+        let fun = BuiltinScalarFunction::Position;

Review Comment:
   I think there is no difference between the two functions, but I just browsed 
the previous implementation, each scalarbilutin function would have a 
corresponding implementation in string_expression, I don't know whether it is 
good to maintain the consistency or not. I can definitely reuse instr though.



-- 
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]

Reply via email to