morrySnow opened a new pull request, #68154: URL: https://github.com/apache/doris/pull/68154
### What problem does this PR solve? Issue Number: [DORIS-27732](https://issues.apache.org/jira/browse/DORIS-27732) Related PR: None Problem Summary: INSERT value normalization directly folds already bound expressions without enabling keepFunctionSignature. When repeat inside struct is folded from an AlwaysNullable function to a non-null string literal, CreateStruct.withChildren can recompute the nested field nullability while surrounding array and cast nodes retain their bound types. FE then sends an inconsistent nested column layout and BE aborts when casting the string column to ColumnNullable. Preserve the bound function signature around both post-bind constant-folding entry points in InsertUtils. Add regression coverage for both fast and normal INSERT VALUES analysis paths. ### Release note Fix BE crashes when inserting arrays of structs containing foldable nullable functions. ### Check List (For Author) - Test - [x] Regression test - [ ] Unit Test - [x] Manual test - Ran the Jira reproduction with enable_fast_analyze_into_values set to both true and false. - Ran ./run-regression-test.sh --conf regression-test/conf/regression-conf.groovy.custom --run -d query_p0/insert_into_table -s test_insert_array_struct_function_signature. - Ran ./build.sh --fe and FE Checkstyle. - [ ] No need to test or manual test. - Behavior changed: - [ ] No. - [x] Yes. INSERT constant folding now preserves the function signature selected during binding. - Does this need documentation? - [x] No. - [ ] Yes. ### Check List (For Reviewer who merge this PR) - [ ] Confirm the release note - [ ] Confirm test cases - [ ] Confirm document - [ ] Add branch pick label -- 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]
