From cc85c10158c9ff03525f2769b449c989de7b5b06 Mon Sep 17 00:00:00 2001 From: Alexey Ozeritskiy Date: Wed, 26 Jun 2024 13:26:17 +0200 Subject: [PATCH] Print actual decimal type on type mismatch --- ydb/library/yql/core/type_ann/type_ann_core.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ydb/library/yql/core/type_ann/type_ann_core.cpp b/ydb/library/yql/core/type_ann/type_ann_core.cpp index 8a05eec93e69..e6764df77674 100644 --- a/ydb/library/yql/core/type_ann/type_ann_core.cpp +++ b/ydb/library/yql/core/type_ann/type_ann_core.cpp @@ -2749,7 +2749,9 @@ namespace NTypeAnnImpl { if (!(*dataTypeOne == *dataTypeTwo)) { ctx.Expr.AddError(TIssue( ctx.Expr.GetPosition(input->Pos()), - TStringBuilder() << "Cannot calculate with different decimals." + TStringBuilder() << "Cannot calculate with different decimals: " + << static_cast(*dataType[0]) << " != " + << static_cast(*dataType[1]) )); return IGraphTransformer::TStatus::Error;