From 80eae25e1e46f423e697ea492698b1f13c99e668 Mon Sep 17 00:00:00 2001 From: jayzhan211 Date: Fri, 1 Mar 2024 20:44:24 +0800 Subject: [PATCH] rename Signed-off-by: jayzhan211 --- datafusion/core/src/physical_planner.rs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/datafusion/core/src/physical_planner.rs b/datafusion/core/src/physical_planner.rs index cb4689f0f2798..f676d37d27ae8 100644 --- a/datafusion/core/src/physical_planner.rs +++ b/datafusion/core/src/physical_planner.rs @@ -1673,7 +1673,7 @@ pub fn create_aggregate_expr_with_name_and_maybe_filter( }; let sort_exprs = order_by.clone().unwrap_or(vec![]); - let phy_order_by = match order_by { + let order_by = match order_by { Some(e) => Some( e.iter() .map(|expr| { @@ -1688,9 +1688,9 @@ pub fn create_aggregate_expr_with_name_and_maybe_filter( None => None, }; - let (agg_expr, filter, phy_order_by) = match func_def { + let (agg_expr, filter, order_by) = match func_def { AggregateFunctionDefinition::BuiltIn(fun) => { - let ordering_reqs = phy_order_by.clone().unwrap_or(vec![]); + let ordering_reqs = order_by.clone().unwrap_or(vec![]); let agg_expr = aggregates::create_aggregate_expr( fun, *distinct, @@ -1699,11 +1699,11 @@ pub fn create_aggregate_expr_with_name_and_maybe_filter( physical_input_schema, name, )?; - (agg_expr, filter, phy_order_by) + (agg_expr, filter, order_by) } AggregateFunctionDefinition::UDF(fun) => { let ordering_reqs: Vec = - phy_order_by.clone().unwrap_or(vec![]); + order_by.clone().unwrap_or(vec![]); let agg_expr = udaf::create_aggregate_expr( fun, @@ -1713,7 +1713,7 @@ pub fn create_aggregate_expr_with_name_and_maybe_filter( physical_input_schema, name, )?; - (agg_expr, filter, phy_order_by) + (agg_expr, filter, order_by) } AggregateFunctionDefinition::Name(_) => { return internal_err!( @@ -1721,7 +1721,7 @@ pub fn create_aggregate_expr_with_name_and_maybe_filter( ) } }; - Ok((agg_expr, filter, phy_order_by)) + Ok((agg_expr, filter, order_by)) } other => internal_err!("Invalid aggregate expression '{other:?}'"), }