Conversation
OIiveirra
requested review from
924060929,
CalvinKirs,
Gabriel39 and
yiguolei
as code owners
September 22, 2026 07:57
Contributor
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
### What problem does this PR solve? Issue Number: None Related PR: None Problem Summary: Iceberg allows a DECIMAL precision increase when the scale is unchanged, but the connector's complex-column diff only allowed integer and floating-point promotions. As a result, ALTER TABLE MODIFY COLUMN rejected STRUCT<field:DECIMAL(5,3)> to STRUCT<field:DECIMAL(10,3)>, breaking Trino Iceberg compatibility tests. Delegate nested primitive promotion validation to Iceberg TypeUtil and cover the persisted top-level complex MODIFY path. Update the existing test that previously asserted the now-supported decimal widening must fail. ### Release note Iceberg complex column changes now support safe nested decimal precision widening. ### Check List (For Author) - Test: FE Iceberg unit tests (84 tests) and external_table_p0/iceberg/test_iceberg_nested_schema_evolution_ddl.groovy (1 suite) - Behavior changed: Yes (safe nested Iceberg decimal precision widening is accepted) - Does this need documentation: No
OIiveirra
force-pushed
the
fix-iceberg-nested-decimal
branch
from
September 22, 2026 08:40
cfe5d1b to
96055e4
Compare
Contributor
Author
|
run buildall |
Contributor
TPC-H: Total hot run time: 28162 ms |
Contributor
TPC-DS: Total hot run time: 152733 ms |
Contributor
ClickBench: Total hot run time: 23.79 s |
Contributor
FE UT Coverage ReportIncrement line coverage `` 🎉 |
Contributor
Author
|
run buildall |
Contributor
TPC-H: Total hot run time: 27229 ms |
Contributor
TPC-DS: Total hot run time: 152014 ms |
Contributor
ClickBench: Total hot run time: 24.04 s |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix Allow nested decimal precision widening
What problem does this PR solve?
Issue Number: None
Related PR: None
Problem Summary: Iceberg allows increasing DECIMAL precision when the scale is unchanged, but Doris rejected this change when the decimal field was nested in a STRUCT, ARRAY, or MAP. The rejection caused the nested decimal schema-evolution cases in the Trino Iceberg compatibility suite to fail. This change delegates nested primitive promotion validation to Iceberg's
TypeUtil, so the connector accepts only promotions supported by Iceberg, including same-scale decimal precision widening, while continuing to reject narrowing and incompatible changes.The regression coverage creates an Iceberg table with
STRUCT<amount:DECIMAL(5,3)>, widens it toSTRUCT<amount:DECIMAL(10,3)>, verifies the resulting schema, and verifies that the pre-existing value12.345remains readable.Release note
Iceberg complex column changes now support safe nested decimal precision widening.
Check List (For Author)
Test
Tests:
IcebergNestedColumnEvolutionTest: 40 passedCatalogBackedIcebergCatalogOpsColumnEvolutionTest: 44 passedexternal_table_p0/iceberg/test_iceberg_nested_schema_evolution_ddl.groovy: 1 suite passed locallyBehavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)