diff --git a/src/common/backend/parser/gram.y b/src/common/backend/parser/gram.y index abc554592..45abf0fce 100644 --- a/src/common/backend/parser/gram.y +++ b/src/common/backend/parser/gram.y @@ -21819,7 +21819,6 @@ policy_label_name: opt_add_resources_to_label: ADD_P resources_to_label_list { $$ = $2; } - | /* EMPTY */ { $$ = NULL; } ; resources_to_label_list: diff --git a/src/test/regress/expected/unsupported_features.out b/src/test/regress/expected/unsupported_features.out index 31e6b98a4..466e8e767 100644 --- a/src/test/regress/expected/unsupported_features.out +++ b/src/test/regress/expected/unsupported_features.out @@ -177,3 +177,15 @@ drop cascades to table uschema2_ix.associate drop cascades to table uschema2_ix.associate_benefit_expense drop cascades to table uschema2_ix.associate_position drop cascades to table uschema2_ix.position_type +create schema create_resource; +set current_schema='create_resource'; +create table tab(a text); +create resource label name; +ERROR: syntax error at or near ";" +LINE 1: create resource label name; + ^ +alter resource label name add column(tab.a); +ERROR: name no such label found +drop table tab; +reset current_schema; +drop schema create_resource CASCADE; diff --git a/src/test/regress/sql/unsupported_features.sql b/src/test/regress/sql/unsupported_features.sql index 2c78ff8e3..b3e8d8644 100644 --- a/src/test/regress/sql/unsupported_features.sql +++ b/src/test/regress/sql/unsupported_features.sql @@ -103,3 +103,13 @@ select position_type_desc, count(*) from uschema2_ix.position_type group by case when length(position_type_cd)>5 then (length(position_type_desc)-20, length(position_type_cd)+1) else (length(position_type_desc)-10, length(position_type_cd)+2) end, 1; drop schema uschema2_ix cascade; + +create schema create_resource; +set current_schema='create_resource'; +create table tab(a text); +create resource label name; +alter resource label name add column(tab.a); + +drop table tab; +reset current_schema; +drop schema create_resource CASCADE; \ No newline at end of file