neilconway commented on code in PR #25389:
URL: https://github.com/apache/datafusion/pull/25389#discussion_r4053648180


##########
datafusion/physical-plan/src/unnest.rs:
##########
@@ -767,7 +768,15 @@ fn flatten_struct_cols(
                 DataType::Struct(_) => {
                     let struct_arr =
                         
column_data.as_any().downcast_ref::<StructArray>().unwrap();
-                    Ok(struct_arr.columns().to_vec())
+                    if struct_arr.null_count() == 0 {
+                        Ok(struct_arr.columns().to_vec())
+                    } else {

Review Comment:
   I don't think we need the special-case here, `apply_parent_nulls` is already 
efficient for the no-nulls case.



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