Commit cfd18437 authored by Michael Meskes's avatar Michael Meskes

- Synced preproc.y with gram.y.

        - Synced pgc.l with scan.l.
        - Synced keyword.c.
        - Set ecpg version to 2.9.0.
        - Set library version to 3.3.0.
parent 0b370ea7
...@@ -1073,3 +1073,11 @@ Thu Apr 5 10:11:35 CEST 2001 ...@@ -1073,3 +1073,11 @@ Thu Apr 5 10:11:35 CEST 2001
- Fixed long long problem. - Fixed long long problem.
- Set ecpg version to 2.8.0. - Set ecpg version to 2.8.0.
- Set library version to 3.2.0. - Set library version to 3.2.0.
Fri Jun 1 08:13:25 CEST 2001
- Synced preproc.y with gram.y.
- Synced pgc.l with scan.l.
- Synced keyword.c.
- Set ecpg version to 2.9.0.
- Set library version to 3.3.0.
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/keywords.c,v 1.40 2001/05/07 00:43:26 tgl Exp $ * $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/keywords.c,v 1.41 2001/06/01 06:23:19 meskes Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -44,6 +44,7 @@ static ScanKeyword ScanKeywords[] = { ...@@ -44,6 +44,7 @@ static ScanKeyword ScanKeywords[] = {
{"as", AS}, {"as", AS},
{"asc", ASC}, {"asc", ASC},
{"at", AT}, {"at", AT},
{"authorization", AUTHORIZATION},
{"backward", BACKWARD}, {"backward", BACKWARD},
{"before", BEFORE}, {"before", BEFORE},
{"begin", BEGIN_TRANS}, {"begin", BEGIN_TRANS},
......
...@@ -172,7 +172,7 @@ make_name(void) ...@@ -172,7 +172,7 @@ make_name(void)
%token TYPECAST %token TYPECAST
/* Keywords (in SQL92 reserved words) */ /* Keywords (in SQL92 reserved words) */
%token ABSOLUTE, ACTION, ADD, ALL, ALTER, AND, ANY, AS, ASC, %token ABSOLUTE, ACTION, ADD, ALL, ALTER, AND, ANY, AS, ASC, AT, AUTHORIZATION,
BEGIN_TRANS, BETWEEN, BOTH, BY, BEGIN_TRANS, BETWEEN, BOTH, BY,
CASCADE, CASE, CAST, CHAIN, CHAR, CHARACTER, CASCADE, CASE, CAST, CHAIN, CHAR, CHARACTER,
CHARACTERISTICS, CHECK, CLOSE, CHARACTERISTICS, CHECK, CLOSE,
...@@ -293,7 +293,7 @@ make_name(void) ...@@ -293,7 +293,7 @@ make_name(void)
%type <str> row_expr row_descriptor row_list ConstDatetime opt_chain %type <str> row_expr row_descriptor row_list ConstDatetime opt_chain
%type <str> SelectStmt into_clause OptTemp ConstraintAttributeSpec %type <str> SelectStmt into_clause OptTemp ConstraintAttributeSpec
%type <str> opt_table opt_all sort_clause sortby_list ConstraintAttr %type <str> opt_table opt_all sort_clause sortby_list ConstraintAttr
%type <str> sortby OptUseOp relation_name_list name_list %type <str> sortby OptUseOp relation_name_list name_list ColId_or_Sconst
%type <str> group_clause having_clause from_clause opt_distinct %type <str> group_clause having_clause from_clause opt_distinct
%type <str> join_outer where_clause relation_expr sub_type opt_arg %type <str> join_outer where_clause relation_expr sub_type opt_arg
%type <str> opt_column_list insert_rest InsertStmt OptimizableStmt %type <str> opt_column_list insert_rest InsertStmt OptimizableStmt
...@@ -802,6 +802,10 @@ VariableSetStmt: SET ColId TO var_value ...@@ -802,6 +802,10 @@ VariableSetStmt: SET ColId TO var_value
{ {
$$ = cat2_str(make_str("set names"), $3); $$ = cat2_str(make_str("set names"), $3);
} }
| SET SESSION AUTHORIZATION ColId_or_Sconst
{
$$ = cat2_str(make_str("set session authorization"), $4);
}
; ;
opt_level: READ COMMITTED { $$ = make_str("read committed"); } opt_level: READ COMMITTED { $$ = make_str("read committed"); }
...@@ -836,6 +840,10 @@ opt_encoding: StringConst { $$ = $1; } ...@@ -836,6 +840,10 @@ opt_encoding: StringConst { $$ = $1; }
| /*EMPTY*/ { $$ = EMPTY; } | /*EMPTY*/ { $$ = EMPTY; }
; ;
ColId_or_Sconst: ColId { $$ = $1; }
| SCONST { $$ = $1; }
;
VariableShowStmt: SHOW ColId VariableShowStmt: SHOW ColId
{ {
$$ = cat2_str(make_str("show"), $2); $$ = cat2_str(make_str("show"), $2);
...@@ -1677,9 +1685,9 @@ comment_text: StringConst { $$ = $1; } ...@@ -1677,9 +1685,9 @@ comment_text: StringConst { $$ = $1; }
* *
*****************************************************************************/ *****************************************************************************/
GrantStmt: GRANT privileges ON relation_name_list TO grantee opt_with_grant GrantStmt: GRANT privileges ON opt_table relation_name_list TO grantee opt_with_grant
{ {
$$ = cat_str(7, make_str("grant"), $2, make_str("on"), $4, make_str("to"), $6); $$ = cat_str(8, make_str("grant"), $2, make_str("on"), $4, $5, make_str("to"), $7);
} }
; ;
...@@ -1727,6 +1735,14 @@ operation: SELECT ...@@ -1727,6 +1735,14 @@ operation: SELECT
{ {
$$ = make_str("rule"); $$ = make_str("rule");
} }
| REFERENCES
{
$$ = make_str("references");
}
| TRIGGER
{
$$ = make_str("trigger");
}
; ;
grantee: PUBLIC grantee: PUBLIC
...@@ -1758,9 +1774,9 @@ opt_with_grant: WITH GRANT OPTION ...@@ -1758,9 +1774,9 @@ opt_with_grant: WITH GRANT OPTION
* *
*****************************************************************************/ *****************************************************************************/
RevokeStmt: REVOKE privileges ON relation_name_list FROM grantee RevokeStmt: REVOKE privileges ON opt_table relation_name_list FROM grantee
{ {
$$ = cat_str(7, make_str("revoke"), $2, make_str("on"), $4, make_str("from"), $6); $$ = cat_str(8, make_str("revoke"), $2, make_str("on"), $4, $5, make_str("from"), $7);
} }
; ;
...@@ -4939,6 +4955,7 @@ TokenId: ABSOLUTE { $$ = make_str("absolute"); } ...@@ -4939,6 +4955,7 @@ TokenId: ABSOLUTE { $$ = make_str("absolute"); }
| AGGREGATE { $$ = make_str("aggregate"); } | AGGREGATE { $$ = make_str("aggregate"); }
| ALTER { $$ = make_str("alter"); } | ALTER { $$ = make_str("alter"); }
| AT { $$ = make_str("at"); } | AT { $$ = make_str("at"); }
| AUTHORIZATION { $$ = make_str("authorization"); }
| BACKWARD { $$ = make_str("backward"); } | BACKWARD { $$ = make_str("backward"); }
| BEFORE { $$ = make_str("before"); } | BEFORE { $$ = make_str("before"); }
| BEGIN_TRANS { $$ = make_str("begin"); } | BEGIN_TRANS { $$ = make_str("begin"); }
......
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