officialasishkumar commented on code in PR #21454:
URL: https://github.com/apache/datafusion/pull/21454#discussion_r3064768547


##########
datafusion/sql/src/expr/mod.rs:
##########
@@ -306,10 +306,22 @@ impl<S: ContextProvider> SqlToRel<'_, S> {
                 data_type,
                 value,
                 uses_odbc_syntax: _,
-            }) => Ok(Expr::Cast(Cast::new_from_field(
-                Box::new(lit(value.into_string().unwrap())),
-                self.convert_data_type_to_field(&data_type)?,
-            ))),
+            }) => {
+                let raw_value = value.to_string();

Review Comment:
   Adjusted this to avoid the happy-path allocation in f416e7120.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to