Commit a6964bc1 authored by Peter Eisentraut's avatar Peter Eisentraut

Remove unnecessary grammar symbols

Instead of publication_name_list, we can use name_list.  We already
refer to publications everywhere else by the 'name' or 'name_list'
symbols, so this only improves consistency.

Reviewed-by: https://www.postgresql.org/message-id/flat/3e3ccddb-41bd-ecd8-29fe-195e34d9886f%40enterprisedb.com
Discussion: Tom Lane <tgl@sss.pgh.pa.us>
parent 8ae4ef4f
...@@ -414,7 +414,6 @@ static Node *makeRecursiveViewSelect(char *relname, List *aliases, Node *query); ...@@ -414,7 +414,6 @@ static Node *makeRecursiveViewSelect(char *relname, List *aliases, Node *query);
relation_expr_list dostmt_opt_list relation_expr_list dostmt_opt_list
transform_element_list transform_type_list transform_element_list transform_type_list
TriggerTransitions TriggerReferencing TriggerTransitions TriggerReferencing
publication_name_list
vacuum_relation_list opt_vacuum_relation_list vacuum_relation_list opt_vacuum_relation_list
drop_option_list drop_option_list
...@@ -422,7 +421,6 @@ static Node *makeRecursiveViewSelect(char *relname, List *aliases, Node *query); ...@@ -422,7 +421,6 @@ static Node *makeRecursiveViewSelect(char *relname, List *aliases, Node *query);
%type <node> group_by_item empty_grouping_set rollup_clause cube_clause %type <node> group_by_item empty_grouping_set rollup_clause cube_clause
%type <node> grouping_sets_clause %type <node> grouping_sets_clause
%type <node> opt_publication_for_tables publication_for_tables %type <node> opt_publication_for_tables publication_for_tables
%type <value> publication_name_item
%type <list> opt_fdw_options fdw_options %type <list> opt_fdw_options fdw_options
%type <defelt> fdw_option %type <defelt> fdw_option
...@@ -9512,7 +9510,7 @@ AlterPublicationStmt: ...@@ -9512,7 +9510,7 @@ AlterPublicationStmt:
*****************************************************************************/ *****************************************************************************/
CreateSubscriptionStmt: CreateSubscriptionStmt:
CREATE SUBSCRIPTION name CONNECTION Sconst PUBLICATION publication_name_list opt_definition CREATE SUBSCRIPTION name CONNECTION Sconst PUBLICATION name_list opt_definition
{ {
CreateSubscriptionStmt *n = CreateSubscriptionStmt *n =
makeNode(CreateSubscriptionStmt); makeNode(CreateSubscriptionStmt);
...@@ -9524,20 +9522,6 @@ CreateSubscriptionStmt: ...@@ -9524,20 +9522,6 @@ CreateSubscriptionStmt:
} }
; ;
publication_name_list:
publication_name_item
{
$$ = list_make1($1);
}
| publication_name_list ',' publication_name_item
{
$$ = lappend($1, $3);
}
;
publication_name_item:
ColLabel { $$ = makeString($1); };
/***************************************************************************** /*****************************************************************************
* *
* ALTER SUBSCRIPTION name ... * ALTER SUBSCRIPTION name ...
...@@ -9572,7 +9556,7 @@ AlterSubscriptionStmt: ...@@ -9572,7 +9556,7 @@ AlterSubscriptionStmt:
n->options = $6; n->options = $6;
$$ = (Node *)n; $$ = (Node *)n;
} }
| ALTER SUBSCRIPTION name SET PUBLICATION publication_name_list opt_definition | ALTER SUBSCRIPTION name SET PUBLICATION name_list opt_definition
{ {
AlterSubscriptionStmt *n = AlterSubscriptionStmt *n =
makeNode(AlterSubscriptionStmt); makeNode(AlterSubscriptionStmt);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment