andygrove commented on code in PR #13717:
URL: https://github.com/apache/datafusion/pull/13717#discussion_r1880143143


##########
datafusion/functions/src/datetime/date_part.rs:
##########
@@ -148,7 +148,9 @@ impl ScalarUDFImpl for DatePartFunc {
     }
 
     fn return_type(&self, _arg_types: &[DataType]) -> Result<DataType> {
-        internal_err!("return_type_from_exprs shoud be called instead")
+        // return type could be Float32 or Int32 depending on the input 
arguments
+        // return_type_from_exprs should be called instead
+        Ok(DataType::Float64)

Review Comment:
   I have reverted this change now. 



-- 
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: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to