Skip to content

Reduce repetition in try_process_group_by_unnest and try_process_unnest #11498

@alamb

Description

@alamb

This function seems to have some code repetition with function try_process_unnest.

I wonder if there's a better way to handle this, such as planning unnest before aggregation, and then reusing the current group-by planning logic. This seems more intuitive to me. But I'm not sure about it.

Originally posted by @jonahgao in #11469 (comment)

The idea is to remove the repetition, and possibly also this comment as well: https://github.com/apache/datafusion/pull/11469/files#r1678995060

If unnest has already been processed by try_process_aggregate_unnest, does the following logic for handling unnest become redundant?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions