[fix](load) Fix src slot mapping issue when file columns are not explicitly specified#56041
Conversation
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
|
run buildall |
|
PR approved by at least one committer and no changes requested. |
|
PR approved by anyone and no changes requested. |
TPC-H: Total hot run time: 34648 ms |
TPC-DS: Total hot run time: 186012 ms |
ClickBench: Total hot run time: 29.65 s |
FE UT Coverage ReportIncrement line coverage |
FE Regression Coverage ReportIncrement line coverage |
|
run buildall |
FE UT Coverage ReportIncrement line coverage |
TPC-H: Total hot run time: 34846 ms |
TPC-DS: Total hot run time: 187928 ms |
ClickBench: Total hot run time: 30.3 s |
FE Regression Coverage ReportIncrement line coverage |
|
PR approved by at least one committer and no changes requested. |
| // Only track columns with constant expressions (e.g., "k1 = 'constant'") | ||
| // Non-constant expressions (e.g., "k1 = k1 + 1") still need to read from file | ||
| if (importColumnDesc.getExpr().isConstant()) { | ||
| constantMappingColumns.add(mappingColumnName); | ||
| } |
There was a problem hiding this comment.
对于 column = now() 这种情况,这段逻辑可以正确处理么?
### What problem does this PR solve? Related PR: [#xxx](apache#56041) Problem Summary: improve apache#56041 before this pr: we can only use `c1 = 72105107105`, `c2 = "ykiko"`, these constant values in load. after this pr : we can use `c1 = uuid()`, `c2 = abs(-2)+1`, `c3 = now()`, these constant function.
What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
When users specify only SET expressions (e.g., 'kd01=20230102') without explicit file column mapping, the system incorrectly auto-generates file columns that include columns meant for SET expressions only.
Root cause:
Issues caused:
missing from source file
Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)