*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.24 1998/08/24 01:13:44 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.25 1998/08/25 15:04:23 thomas Exp $
*
* HISTORY
* AUTHOR DATE MAJOR EVENT
LANCOMPILER, LISTEN, LOAD, LOCK_P, LOCATION, MAXVALUE, MINVALUE, MOVE,
NEW, NONE, NOTHING, NOTNULL, OIDS, OPERATOR, PROCEDURAL,
RECIPE, RENAME, RESET, RETURNS, ROW, RULE,
- SEQUENCE, SETOF, SHOW, START, STATEMENT, STDIN, STDOUT, TRUSTED,
+ SEQUENCE, SERIAL, SETOF, SHOW, START, STATEMENT, STDIN, STDOUT, TRUSTED,
VACUUM, VERBOSE, VERSION, ENCODING
/* Keywords (obsolete; retain through next version for parser - thomas 1997-12-04) */
n->defval = NULL;
n->is_not_null = FALSE;
n->constraints = $3;
+ $$ = (Node *)n;
+ }
+ | ColId SERIAL
+ {
+ ColumnDef *n = makeNode(ColumnDef);
+ n->colname = $1;
+ n->typename = makeNode(TypeName);
+ n->typename->name = xlateSqlType("integer");
+ n->defval = NULL;
+ n->is_not_null = TRUE;
+ n->is_sequence = TRUE;
+ n->constraints = NULL;
+
$$ = (Node *)n;
}
;
| PRIVILEGES { $$ = "privileges"; }
| RECIPE { $$ = "recipe"; }
| ROW { $$ = "row"; }
+ | SERIAL { $$ = "serial"; }
| START { $$ = "start"; }
| STATEMENT { $$ = "statement"; }
| TIME { $$ = "time"; }