Skip to content

Commit

Permalink
issue 361 fixed type issue for eval_mode in planner.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
prashantksharma committed May 11, 2024
1 parent f48bd93 commit 5e6a35c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions core/src/execution/datafusion/planner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -346,10 +346,10 @@ impl PhysicalPlanner {
let child = self.create_expr(expr.child.as_ref().unwrap(), input_schema)?;
let datatype = to_arrow_datatype(expr.datatype.as_ref().unwrap());
let timezone = expr.timezone.clone();
let eval_mode = match expr.eval_mode.as_str() {
"ANSI" => EvalMode::Ansi,
"TRY" => EvalMode::Try,
"LEGACY" => EvalMode::Legacy,
let eval_mode = match expr.eval_mode {
0 => EvalMode::Legacy,
1 => EvalMode::Try,
2 => EvalMode::Ansi,
other => {
return Err(ExecutionError::GeneralError(format!(
"Invalid Cast EvalMode: \"{other}\""
Expand Down

0 comments on commit 5e6a35c

Please sign in to comment.