Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
37d937ea
Commit
37d937ea
authored
Aug 22, 2004
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Code review for ALTER INDEX patch.
parent
235caf4b
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
11 deletions
+18
-11
src/backend/commands/alter.c
src/backend/commands/alter.c
+3
-1
src/backend/nodes/copyfuncs.c
src/backend/nodes/copyfuncs.c
+2
-1
src/backend/nodes/equalfuncs.c
src/backend/nodes/equalfuncs.c
+2
-1
src/backend/parser/analyze.c
src/backend/parser/analyze.c
+2
-1
src/backend/parser/gram.y
src/backend/parser/gram.y
+9
-7
No files found.
src/backend/commands/alter.c
View file @
37d937ea
...
...
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/commands/alter.c,v 1.
8 2004/06/25 21:55:53
tgl Exp $
* $PostgreSQL: pgsql/src/backend/commands/alter.c,v 1.
9 2004/08/22 00:08:27
tgl Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -89,6 +89,7 @@ ExecRenameStmt(RenameStmt *stmt)
break
;
case
OBJECT_TABLE
:
case
OBJECT_INDEX
:
case
OBJECT_COLUMN
:
case
OBJECT_TRIGGER
:
{
...
...
@@ -101,6 +102,7 @@ ExecRenameStmt(RenameStmt *stmt)
switch
(
stmt
->
renameType
)
{
case
OBJECT_TABLE
:
case
OBJECT_INDEX
:
{
/*
* RENAME TABLE requires that we (still) hold
...
...
src/backend/nodes/copyfuncs.c
View file @
37d937ea
...
...
@@ -15,7 +15,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/copyfuncs.c,v 1.2
89 2004/08/02 04:26:05
tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/copyfuncs.c,v 1.2
90 2004/08/22 00:08:28
tgl Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -1626,6 +1626,7 @@ _copyAlterTableStmt(AlterTableStmt *from)
COPY_NODE_FIELD
(
relation
);
COPY_NODE_FIELD
(
cmds
);
COPY_SCALAR_FIELD
(
relkind
);
return
newnode
;
}
...
...
src/backend/nodes/equalfuncs.c
View file @
37d937ea
...
...
@@ -18,7 +18,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/equalfuncs.c,v 1.22
8 2004/08/02 04:26:05
tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/equalfuncs.c,v 1.22
9 2004/08/22 00:08:28
tgl Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -727,6 +727,7 @@ _equalAlterTableStmt(AlterTableStmt *a, AlterTableStmt *b)
{
COMPARE_NODE_FIELD
(
relation
);
COMPARE_NODE_FIELD
(
cmds
);
COMPARE_SCALAR_FIELD
(
relkind
);
return
true
;
}
...
...
src/backend/parser/analyze.c
View file @
37d937ea
...
...
@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $PostgreSQL: pgsql/src/backend/parser/analyze.c,v 1.30
8 2004/08/02 04:26:29
tgl Exp $
* $PostgreSQL: pgsql/src/backend/parser/analyze.c,v 1.30
9 2004/08/22 00:08:28
tgl Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -1421,6 +1421,7 @@ transformFKConstraints(ParseState *pstate, CreateStmtContext *cxt,
alterstmt
->
relation
=
cxt
->
relation
;
alterstmt
->
cmds
=
NIL
;
alterstmt
->
relkind
=
OBJECT_TABLE
;
foreach
(
fkclist
,
cxt
->
fkconstraints
)
{
...
...
src/backend/parser/gram.y
View file @
37d937ea
...
...
@@ -11,7 +11,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/parser/gram.y,v 2.47
2 2004/08/20 04:29:32 momjian
Exp $
* $PostgreSQL: pgsql/src/backend/parser/gram.y,v 2.47
3 2004/08/22 00:08:28 tgl
Exp $
*
* HISTORY
* AUTHOR DATE MAJOR EVENT
...
...
@@ -1166,6 +1166,7 @@ alter_table_cmds:
| alter_table_cmds ',' alter_table_cmd { $$ = lappend($1, $3); }
;
/* Subcommands that are for ALTER TABLE only */
alter_table_cmd:
/* ALTER TABLE <relation> ADD [COLUMN] <coldef> */
ADD opt_column columnDef
...
...
@@ -1293,13 +1294,14 @@ alter_table_cmd:
}
;
alter_rel_cmds:
alter_rel_cmd { $$ = list_make1($1); }
| alter_rel_cmds ',' alter_rel_cmd { $$ = lappend($1, $3
); }
;
alter_rel_cmds:
alter_rel_cmd { $$ = list_make1($1
); }
| alter_rel_cmds ',' alter_rel_cmd { $$ = lappend($1, $3); }
;
/* Subcommands that are for ALTER TABLE or ALTER INDEX */
alter_rel_cmd:
/* ALTER [
TABLE | INDEX
] <name> OWNER TO UserId */
/* ALTER [
TABLE|INDEX
] <name> OWNER TO UserId */
OWNER TO UserId
{
AlterTableCmd *n = makeNode(AlterTableCmd);
...
...
@@ -1307,7 +1309,7 @@ alter_rel_cmd:
n->name = $3;
$$ = (Node *)n;
}
/* ALTER [
TABLE | INDEX
] <name> SET TABLESPACE <tablespacename> */
/* ALTER [
TABLE|INDEX
] <name> SET TABLESPACE <tablespacename> */
| SET TABLESPACE name
{
AlterTableCmd *n = makeNode(AlterTableCmd);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment