mirror of
https://github.com/postgres/postgres.git
synced 2025-11-10 17:42:29 +03:00
Todo items:
Add ALTER SEQUENCE to modify min/max/increment/cache/cycle values Also updated create sequence docs to mention NO MINVALUE, & NO MAXVALUE. New Files: doc/src/sgml/ref/alter_sequence.sgml src/test/regress/expected/sequence.out src/test/regress/sql/sequence.sql ALTER SEQUENCE is NOT transactional. It behaves similarly to setval(). It matches the proposed SQL200N spec, as well as Oracle in most ways -- Oracle lacks RESTART WITH for some strange reason. -- Rod Taylor <rbt@rbt.ca>
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.189 2003/03/10 03:53:49 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.190 2003/03/20 07:02:08 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -1066,6 +1066,15 @@ _equalCreateSeqStmt(CreateSeqStmt *a, CreateSeqStmt *b)
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool
|
||||
_equalAlterSeqStmt(AlterSeqStmt *a, AlterSeqStmt *b)
|
||||
{
|
||||
COMPARE_NODE_FIELD(sequence);
|
||||
COMPARE_NODE_FIELD(options);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool
|
||||
_equalVariableSetStmt(VariableSetStmt *a, VariableSetStmt *b)
|
||||
{
|
||||
@@ -1864,6 +1873,9 @@ equal(void *a, void *b)
|
||||
case T_CreateSeqStmt:
|
||||
retval = _equalCreateSeqStmt(a, b);
|
||||
break;
|
||||
case T_AlterSeqStmt:
|
||||
retval = _equalAlterSeqStmt(a, b);
|
||||
break;
|
||||
case T_VariableSetStmt:
|
||||
retval = _equalVariableSetStmt(a, b);
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user