mirror of
https://github.com/postgres/postgres.git
synced 2025-05-21 15:54:08 +03:00
Fix SERIAL columns, which Thomas inadvertently broke parsing of.
Revised code probably accepts some silly combinations, but that's better than not accepting valid ones.
This commit is contained in:
parent
751a14e60c
commit
37a71f90b2
@ -11,7 +11,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.146 2000/02/19 19:37:21 tgl Exp $
|
* $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.147 2000/02/20 02:14:58 tgl Exp $
|
||||||
*
|
*
|
||||||
* HISTORY
|
* HISTORY
|
||||||
* AUTHOR DATE MAJOR EVENT
|
* AUTHOR DATE MAJOR EVENT
|
||||||
@ -1047,7 +1047,7 @@ columnDef: ColId Typename ColQualifier opt_collate
|
|||||||
|
|
||||||
$$ = (Node *)n;
|
$$ = (Node *)n;
|
||||||
}
|
}
|
||||||
| ColId SERIAL PrimaryKey
|
| ColId SERIAL ColQualifier opt_collate
|
||||||
{
|
{
|
||||||
ColumnDef *n = makeNode(ColumnDef);
|
ColumnDef *n = makeNode(ColumnDef);
|
||||||
n->colname = $1;
|
n->colname = $1;
|
||||||
@ -1060,7 +1060,11 @@ columnDef: ColId Typename ColQualifier opt_collate
|
|||||||
#endif
|
#endif
|
||||||
n->is_not_null = TRUE;
|
n->is_not_null = TRUE;
|
||||||
n->is_sequence = TRUE;
|
n->is_sequence = TRUE;
|
||||||
n->constraints = lcons($3, NIL);
|
n->constraints = $3;
|
||||||
|
|
||||||
|
if ($4 != NULL)
|
||||||
|
elog(NOTICE,"CREATE TABLE/COLLATE %s not yet implemented"
|
||||||
|
"; clause ignored", $4);
|
||||||
|
|
||||||
$$ = (Node *)n;
|
$$ = (Node *)n;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user