kumarUjjawal commented on code in PR #20116:
URL: https://github.com/apache/datafusion/pull/20116#discussion_r2762324561


##########
datafusion/spark/src/function/hash/sha2.rs:
##########
@@ -87,7 +88,97 @@ impl ScalarUDFImpl for SparkSha2 {
     }
 
     fn invoke_with_args(&self, args: ScalarFunctionArgs) -> 
Result<ColumnarValue> {
-        make_scalar_function(sha2_impl, vec![])(&args.args)
+        let [values, bit_lengths] = take_function_args(self.name(), 
args.args.iter())?;
+
+        match (values, bit_lengths) {
+            (
+                ColumnarValue::Scalar(value_scalar),
+                ColumnarValue::Scalar(ScalarValue::Int32(Some(bit_length))),
+            ) => {
+                if value_scalar.is_null() {

Review Comment:
   Should i make the changes in this pr or will these be in the follow up too?



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