yjshen commented on code in PR #2375:
URL: https://github.com/apache/arrow-datafusion/pull/2375#discussion_r866978192


##########
datafusion/physical-expr/src/aggregate/sum.rs:
##########
@@ -315,6 +354,84 @@ pub(crate) fn sum(lhs: &ScalarValue, rhs: &ScalarValue) -> 
Result<ScalarValue> {
     })
 }
 
+pub(crate) fn add_to_row(
+    dt: &DataType,
+    index: usize,
+    accessor: &mut RowAccessor,
+    s: &ScalarValue,
+) -> Result<()> {
+    match (dt, s) {
+        // float64 coerces everything to f64

Review Comment:
   Agree. We should clean this up by probably by checking type coercions.



-- 
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]

Reply via email to