andishgar opened a new issue, #50516: URL: https://github.com/apache/arrow/issues/50516
### Describe the bug, including details regarding any error messages, version, and platform. As mentioned [here](https://arrow.apache.org/docs/format/Columnar.html#struct-validity), determining whether a struct child is null in Arrow requires taking the logical AND of the parent and child validity bitmaps. > Therefore, to know whether a particular child entry is valid, one must take the logical AND of the corresponding bits in the two validity bitmaps (the struct array's and the child array's). However, the following assertion passes: ```c++ auto struct_type = struct_({field("a", float32())}); auto float_builder = std::make_shared<FloatBuilder>(pool_); StructBuilder builder(struct_type, pool_, {float_builder}); ASSERT_OK(builder.Append(1)); ASSERT_OK(float_builder->AppendNull()); ASSERT_OK_AND_ASSIGN(auto array, builder.Finish()); // This assertion passes, but the expected result is false. ASSERT_TRUE(array->IsValid(0)); ``` ### Component(s) C++ -- 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]
