*** a/src/backend/parser/gram.y --- b/src/backend/parser/gram.y *************** *** 529,534 **** static Node *makeRecursiveViewSelect(char *relname, List *aliases, Node *query); --- 529,535 ---- %type Iconst SignedIconst %type Sconst comment_text notify_payload %type RoleId opt_boolean_or_string + %type opt_boolean_or_string_or_numeric %type var_list %type ColId ColLabel var_name type_function_name param_name %type NonReservedWord NonReservedWord_or_Sconst *************** *** 1584,1589 **** iso_level: READ UNCOMMITTED { $$ = "read uncommitted"; } --- 1585,1595 ---- | SERIALIZABLE { $$ = "serializable"; } ; + opt_boolean_or_string_or_numeric: + opt_boolean_or_string { $$ = (Node *) makeString($1); } + | NumericOnly { $$ = (Node *) $1; } + ; + opt_boolean_or_string: TRUE_P { $$ = "true"; } | FALSE_P { $$ = "false"; } *************** *** 3099,3106 **** copy_generic_opt_elem: ; copy_generic_opt_arg: ! opt_boolean_or_string { $$ = (Node *) makeString($1); } ! | NumericOnly { $$ = (Node *) $1; } | '*' { $$ = (Node *) makeNode(A_Star); } | '(' copy_generic_opt_arg_list ')' { $$ = (Node *) $2; } | /* EMPTY */ { $$ = NULL; } --- 3105,3111 ---- ; copy_generic_opt_arg: ! opt_boolean_or_string_or_numeric { $$ = $1; } | '*' { $$ = (Node *) makeNode(A_Star); } | '(' copy_generic_opt_arg_list ')' { $$ = (Node *) $2; } | /* EMPTY */ { $$ = NULL; } *************** *** 10582,10588 **** vac_analyze_option_name: ; vac_analyze_option_arg: ! opt_boolean_or_string { $$ = (Node *) makeString($1); } | /* EMPTY */ { $$ = NULL; } ; --- 10587,10593 ---- ; vac_analyze_option_arg: ! opt_boolean_or_string_or_numeric { $$ = $1; } | /* EMPTY */ { $$ = NULL; } ; *************** *** 10707,10714 **** explain_option_name: ; explain_option_arg: ! opt_boolean_or_string { $$ = (Node *) makeString($1); } ! | NumericOnly { $$ = (Node *) $1; } | /* EMPTY */ { $$ = NULL; } ; --- 10712,10718 ---- ; explain_option_arg: ! opt_boolean_or_string_or_numeric { $$ = $1; } | /* EMPTY */ { $$ = NULL; } ;