Skip to content

Commit 5bd08ba

Browse files
committed
Allow column groups with single column
commit_hash:bc699799776c0e43669867c9ef261fb1e006efa4
1 parent cdfd207 commit 5bd08ba

File tree

4 files changed

+5
-17
lines changed

4 files changed

+5
-17
lines changed

yt/yql/providers/yt/provider/yql_yt_op_settings.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -854,9 +854,9 @@ bool ValidateSettings(const TExprNode& settingsNode, EYtSettingTypes accepted, T
854854
<< "Expected list value, group: "
855855
<< it->first.Quote()));
856856
return false;
857-
} else if (it->second.AsList().size() < 2) {
857+
} else if (it->second.AsList().empty()) {
858858
ctx.AddError(TIssue(ctx.GetPosition(setting->Tail().Pos()), TStringBuilder()
859-
<< "Expected list with at least two columns, group: "
859+
<< "Expected non empty column list, group: "
860860
<< it->first.Quote()));
861861
return false;
862862
} else {
@@ -904,7 +904,7 @@ bool ValidateSettings(const TExprNode& settingsNode, EYtSettingTypes accepted, T
904904
return false;
905905
}
906906
}
907-
return true;
907+
break;
908908
}
909909
case EYtSettingType::BlockOutputReady: {
910910
if (!EnsureTupleSize(*setting, 2, ctx)) {
@@ -917,7 +917,7 @@ bool ValidateSettings(const TExprNode& settingsNode, EYtSettingTypes accepted, T
917917
<< "Unsupported block output mode value " << TString{setting->Child(1)->Content()}.Quote()));
918918
return false;
919919
}
920-
return true;
920+
break;
921921
}
922922
case EYtSettingType::QLFilter: {
923923
if (!EnsureTupleSize(*setting, 2, ctx)) {

yt/yql/tests/sql/suites/column_group/hint_empty_grp_fail.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* custom error:Expected list with at least two columns, group: "g1"*/
1+
/* custom error: Expected non empty column list, group: "g1" */
22
USE plato;
33

44
-- empty group

yt/yql/tests/sql/suites/column_group/hint_short_grp_fail.cfg

Lines changed: 0 additions & 5 deletions
This file was deleted.

yt/yql/tests/sql/suites/column_group/hint_short_grp_fail.sql

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)