viirya commented on code in PR #66:
URL: 
https://github.com/apache/arrow-datafusion-comet/pull/66#discussion_r1501931352


##########
core/src/execution/datafusion/expressions/scalar_funcs.rs:
##########
@@ -366,7 +364,12 @@ fn spark_round(
                 let (precision, scale) = get_precision_scale(data_type);
                 make_decimal_array(array, precision, scale, &f)
             }
-            _ => make_scalar_function(math_expressions::round)(args),
+            DataType::Float32 | DataType::Float64 => {
+                Ok(ColumnarValue::Array(math_expressions::round(&[
+                    array.clone()
+                ])?))
+            }
+            dt => exec_err!("Not supported datatype[{dt}] for ROUND"),

Review Comment:
   Hm, why wrap `dt` with `[]`? I don't see there is something in Comet or 
DataFusion.



-- 
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...@arrow.apache.org

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

Reply via email to