Skip to content

Max and Min function on mvfield(s) #49

@tombonfert

Description

@tombonfert
  • Min(X,...) and Max(X,...) functions take an arbitrary number of arguments and return the minimum and maximum per row, respectively.
  • Currently, our implementation is good for single value fields in the input. We are calling Spark's 'least' and 'greatest' method.
  • Our implementation fails or produces wrong results for the following inputs:
    • The only input argument is a mvfield -> Need to call 'array_min' or 'array_max' instead of 'least' or 'greatest'.
    • There are several mvfields as input -> Create array of input arrays -> Flatten -> call array_min / array_max
    • In Splunk it is also possible to provide a mixture of mvfields and svfields in the input.
  • Solution: We need to know the data types of the input arguments.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions