[fix](virtual slot) Materialize constant virtual columns before caching - #67112
Conversation
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
|
I20260825 11:27:38.316625 3244801 fragment_mgr.cpp:504] query_id: 3a4ef02e30ad4a4b-90c6f655611eb4d3, coord_addr: TNetworkAddress(hostname=172.16.0.1, port=29720), total fragment num on current host: 49, fe process uuid: 1787626825489, query type: SELECT, report audit fe:TNetworkAddress(hostname=172.16.0.1, port=29720), use wg:1787626825281,normal |
|
run buildall |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
Problem Summary:
Virtual-column expressions may return ColumnConst, including all-NULL nullable constants. SegmentIterator previously stored these results directly in the
output block, while downstream consumers expect row-aligned concrete columns. This could cause type assertion failures during CSE virtual-column queries with
short-circuit evaluation.
Solution:
Materialize constant expression results with convert_to_full_column_if_const() before caching them in the virtual-column slot.