Stephen Frost wrote:
> Alvaro,
> 
> * Alvaro Herrera (alvhe...@2ndquadrant.com) wrote:
> > ALTER TABLE ALL IN TABLESPACE xyz
> > which AFAICS should work since ALL is already a reserved keyword.
> 
> Pushed to master and REL9_4_STABLE.

Thanks.  One more tweak --- the whole reason for fiddling with this is
to ensure that event triggers support this operation.  Therefore this
node should be handled by ProcessUtilitySlow, not
standard_ProcessUtility, as in the attached patch.

(I checked the documentation for necessary updates; turns out that the
table in the event triggers chapter says that ddl_command_end etc
support the command "ALTER TABLE", and since this is the tag returned by
the new ALTER TABLE ALL IN TABLESPACE command, there is no update
needed.  In fact, one can argue that the table is wrong currently
because it doesn't say that ALTER TABLE ALL IN TABLESPACE is not
supported.)

I propose this for 9.4 too.

> Apologies on it taking so long-
> things have a bit "interesting" for me over the past month or two. :)

I bet they have!  Have fun,

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
diff --git a/src/backend/tcop/utility.c b/src/backend/tcop/utility.c
index 40ac47f..e2c2d3d 100644
--- a/src/backend/tcop/utility.c
+++ b/src/backend/tcop/utility.c
@@ -507,10 +507,6 @@ standard_ProcessUtility(Node *parsetree,
 			AlterTableSpaceOptions((AlterTableSpaceOptionsStmt *) parsetree);
 			break;
 
-		case T_AlterTableMoveAllStmt:
-			AlterTableMoveAll((AlterTableMoveAllStmt *) parsetree);
-			break;
-
 		case T_TruncateStmt:
 			ExecuteTruncate((TruncateStmt *) parsetree);
 			break;
@@ -1296,6 +1292,10 @@ ProcessUtilitySlow(Node *parsetree,
 				AlterTSConfiguration((AlterTSConfigurationStmt *) parsetree);
 				break;
 
+			case T_AlterTableMoveAllStmt:
+				AlterTableMoveAll((AlterTableMoveAllStmt *) parsetree);
+				break;
+
 			case T_DropStmt:
 				ExecDropStmt((DropStmt *) parsetree, isTopLevel);
 				break;
-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to