You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/07/04 08:26:59 UTC

[GitHub] [arrow-datafusion] Jimexist commented on issue #554: implement lead and lag with 2nd and 3rd argument

Jimexist commented on issue #554:
URL: https://github.com/apache/arrow-datafusion/issues/554#issuecomment-873545732


   > Hi @Jimexist, Could I take a look at this ?
   > 
   > 
   > 
   > As I understand it:
   > 
   > * a **BuiltInWindowFunctionExpr** and a **PartitionEvaluator** has to be implemented under _physical_plan/expressions_, **lag** and **lead** functions should be created with a name, an expression, and the offset/default_value optional arguments.
   > 
   > 
   > 
   > * **return_type_for_built_in** and **signature_for_built_in** should be changed for Lag/Lead (physical_plan/window_functions)
   > 
   > 
   > 
   > * signature has to be a **Signature::OneOf**( (expr -> result), (expr, offset) -> result, (expr, offset, default_value) -> result )
   > 
   > 
   > 
   > I'm probably missing some details, but would this approach be valid ?
   
   Go ahead and thanks!
   
   the way is see it currently there is no easy way to express heterogeneity in arg types so i would stick with any and check inside the actual execution phase. 


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org