Skip to content

Commit

Permalink
KE-42126 allow decimal conversion accuracy loss
Browse files Browse the repository at this point in the history
  • Loading branch information
Yu Gan authored and zheniantoushipashi committed Aug 21, 2023
1 parent a0f60da commit b9f98f9
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -3667,7 +3667,8 @@ class Analyzer(override val catalogManager: CatalogManager)
Cast(child, target.asNullable)

case u @ UpCast(child, _, walkedTypePath) if !Cast.canUpCast(child.dataType, u.dataType) =>
fail(child, u.dataType, walkedTypePath)
if (conf.isViewTruncateEnable) child
else fail(child, u.dataType, walkedTypePath)

case u @ UpCast(child, _, _) => Cast(child, u.dataType)
}
Expand Down

0 comments on commit b9f98f9

Please sign in to comment.