Skip to content

Commit

Permalink
Rename Expr::display_name to Expr::schema_name, make UNNEST nam…
Browse files Browse the repository at this point in the history
…ing conform to convention (#11797)

* introduce schema_name

Signed-off-by: jayzhan211 <[email protected]>

* fix

Signed-off-by: jayzhan211 <[email protected]>

* cleanup

Signed-off-by: jayzhan211 <[email protected]>

* cleanup

Signed-off-by: jayzhan211 <[email protected]>

* fix doc

Signed-off-by: jayzhan211 <[email protected]>

* reuse for simple case

Signed-off-by: jayzhan211 <[email protected]>

* unnest + udf

Signed-off-by: jayzhan211 <[email protected]>

* fmt

Signed-off-by: jayzhan211 <[email protected]>

* add display name for udf

Signed-off-by: jayzhan211 <[email protected]>

* fix name in udf

Signed-off-by: jayzhan211 <[email protected]>

* rename unnest

Signed-off-by: jayzhan211 <[email protected]>

* rm column

Signed-off-by: jayzhan211 <[email protected]>

* inlis

Signed-off-by: jayzhan211 <[email protected]>

* fmt

Signed-off-by: jayzhan211 <[email protected]>

* udaf

Signed-off-by: jayzhan211 <[email protected]>

* case

Signed-off-by: jayzhan211 <[email protected]>

* use write

Signed-off-by: jayzhan211 <[email protected]>

* fix test

Signed-off-by: jayzhan211 <[email protected]>

* fix window

Signed-off-by: jayzhan211 <[email protected]>

* window

Signed-off-by: jayzhan211 <[email protected]>

* like and similar to

Signed-off-by: jayzhan211 <[email protected]>

* rm display name

Signed-off-by: jayzhan211 <[email protected]>

* comment

Signed-off-by: jayzhan211 <[email protected]>

* cliip

Signed-off-by: jayzhan211 <[email protected]>

* fix doc

Signed-off-by: jayzhan211 <[email protected]>

* display

Signed-off-by: jayzhan211 <[email protected]>

* fix conflict

Signed-off-by: jayzhan211 <[email protected]>

* fix merge conflict

Signed-off-by: jayzhan211 <[email protected]>

* with display

Signed-off-by: jayzhan211 <[email protected]>

* function for exprs

Signed-off-by: jayzhan211 <[email protected]>

* clippy

Signed-off-by: jayzhan211 <[email protected]>

* fix doc

Signed-off-by: jayzhan211 <[email protected]>

---------

Signed-off-by: jayzhan211 <[email protected]>
  • Loading branch information
jayzhan211 authored Aug 9, 2024
1 parent 56f8e35 commit 7c41323
Show file tree
Hide file tree
Showing 30 changed files with 494 additions and 426 deletions.
4 changes: 2 additions & 2 deletions datafusion/core/src/physical_planner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1529,7 +1529,7 @@ pub fn create_window_expr(
// unpack aliased logical expressions, e.g. "sum(col) over () as total"
let (name, e) = match e {
Expr::Alias(Alias { expr, name, .. }) => (name.clone(), expr.as_ref()),
_ => (e.display_name()?, e),
_ => (e.schema_name().to_string(), e),
};
create_window_expr_with_name(e, name, logical_schema, execution_props)
}
Expand Down Expand Up @@ -1620,7 +1620,7 @@ pub fn create_aggregate_expr_and_maybe_filter(
// unpack (nested) aliased logical expressions, e.g. "sum(col) as total"
let (name, e) = match e {
Expr::Alias(Alias { expr, name, .. }) => (Some(name.clone()), expr.as_ref()),
Expr::AggregateFunction(_) => (e.display_name().ok(), e),
Expr::AggregateFunction(_) => (Some(e.schema_name().to_string()), e),
_ => (None, e),
};

Expand Down
Loading

0 comments on commit 7c41323

Please sign in to comment.