tustvold commented on code in PR #3612:
URL: https://github.com/apache/arrow-datafusion/pull/3612#discussion_r979434005


##########
datafusion/proto/proto/datafusion.proto:
##########
@@ -739,11 +742,19 @@ message IntervalMonthDayNanoValue {
   int64 nanos = 3;
 }
 
+message StructValue {
+  // encode null explicitly to distinguish a struct with no fields (is
+  // that possible?) from a null value
+  bool is_null = 1;
+  repeated ScalarValue field_values = 2;
+  repeated Field fields = 3;
+}
 
 message ScalarValue{
     oneof value {
-        // Null value of any type (type is encoded)
-        PrimitiveScalarType null_value = 19;
+        // was PrimitiveScalarType null_value = 19;
+        // Null value of any type
+        ArrowType null_value = 33;

Review Comment:
   This might be a dumb question but why are nulls typed? This encoding of 
scalarvalue seems to conflate encoding the schema with encoding the values, 
which seems unfortunate.
   
   Perhaps we could take a look at what substrait does and copy that?



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