Skip to content

Conversation

@adriangb
Copy link
Contributor

No description provided.

@github-actions github-actions bot added logical-expr Logical plan and expressions physical-expr Changes to the physical-expr crates optimizer Optimizer rules sqllogictest SQL Logic Tests (.slt) functions Changes to functions implementation physical-plan Changes to the physical-plan crate labels Jan 27, 2026
@adriangb adriangb force-pushed the column-path-functions-logical branch 2 times, most recently from 73474e9 to 8f00c20 Compare January 27, 2026 20:50
@adriangb adriangb force-pushed the column-path-functions-logical branch from 8f00c20 to 36dda08 Compare January 27, 2026 22:22
adriangb added a commit to pydantic/datafusion that referenced this pull request Jan 29, 2026
… decisions

This extracts the ExpressionPlacement enum from PR apache#20036 to provide a
mechanism for expressions to indicate where they should be placed in
the query plan for optimal execution.

Changes:
- Add ExpressionPlacement enum with variants: Literal, Column,
  PlaceAtLeaves, PlaceAtRoot
- Add placement() method to Expr, ScalarUDF, ScalarUDFImpl traits
- Add placement() method to PhysicalExpr trait and implementations
- Implement placement() for GetFieldFunc to return PlaceAtLeaves when
  accessing struct fields with literal keys
- Replace is_expr_trivial() checks with placement() in optimizer and
  physical-plan projection code

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

functions Changes to functions implementation logical-expr Logical plan and expressions optimizer Optimizer rules physical-expr Changes to the physical-expr crates physical-plan Changes to the physical-plan crate sqllogictest SQL Logic Tests (.slt)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant