Skip to content

Port min and max with Spark semantics for floats and structs from Comet #161

Open

Description

@andygrove

Note

An LLM (Claude Code) created this issue. It compared the native expressions in Apache DataFusion Comet (native/spark-expr) with the functions in this crate. Check the details before you rely on them.

Is your feature request related to a problem or challenge?

Comet has a native, Spark-compatible implementation of min and max with Spark semantics for floats and structs that datafusion-spark does not have.

Spark expressions: min, max

Comet source (at 3878424d9):

Spark orders NaN above every other value and treats -0.0 as equal to 0.0.

Describe the solution you'd like

Port the implementation and its tests from Comet into datafusion-spark, and add .slt cases under crates/sqllogictest. Comet can then use the datafusion-spark version and remove its copy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions