mrhhsg commented on code in PR #63528:
URL: https://github.com/apache/doris/pull/63528#discussion_r4227755657
##########
be/src/storage/segment/segment.cpp:
##########
@@ -927,10 +927,11 @@ Status Segment::new_default_iterator(const TabletColumn&
tablet_column,
"column_type={}",
tablet_column.unique_id(), tablet_column.name(),
tablet_column.type());
}
+ auto serde = remove_nullable(tablet_column.get_vec_type())->get_serde();
Review Comment:
Fixed in 63f64a36c00. `Segment::new_default_iterator` builds the SerDe only
when `has_default_value()` and the text is not `NULL`, which mirrors the two
branches of `DefaultValueColumnIterator::init` that never parse. The iterator
no longer falls back to a `DataTypeFactory` scalar type (wrong for nested types
anyway) and asserts `DORIS_CHECK(_serde != nullptr)` when it must parse; its
unused `FieldType/precision/scale/len` members are dropped. New BE UTs:
`ColumnReaderTest.DefaultValueIteratorNeedsNoSerDeForNullDefault` (NULL default
and no-default nullable column with a null SerDe) and
`DefaultValueIteratorParsesComplexDefaultWithSerDe` (`[1, NULL, 3]` through the
iterator into a nullable array column).
--
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]