aboutsummaryrefslogtreecommitdiff
path: root/src/backend/tcop
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>2002-11-15 03:09:39 +0000
committerBruce Momjian <bruce@momjian.us>2002-11-15 03:09:39 +0000
commit8bc717cb8878ff2baee4e29553736fab57248436 (patch)
tree69fb91e37bc3cd3d19e9aa529e3f03002ddf3719 /src/backend/tcop
parent5b7eb4dd45359e040cd7175f1b3cfc5ea28ad138 (diff)
downloadpostgresql-8bc717cb8878ff2baee4e29553736fab57248436.tar.gz
postgresql-8bc717cb8878ff2baee4e29553736fab57248436.zip
New version attached. The following is implemented:
- CLUSTER ALL clusters all the tables that have some index with indisclustered set and the calling user owns. - CLUSTER tablename clusters the named table, using the index with indisclustered set. If no index has the bit set, throws elog(ERROR). - The multi-relation version (CLUSTER ALL) uses a multitransaction approach, similar to what VACUUM does. Alvaro Herrera
Diffstat (limited to 'src/backend/tcop')
-rw-r--r--src/backend/tcop/utility.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/backend/tcop/utility.c b/src/backend/tcop/utility.c
index ddd5c7626a6..493dbd7587a 100644
--- a/src/backend/tcop/utility.c
+++ b/src/backend/tcop/utility.c
@@ -10,7 +10,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/utility.c,v 1.181 2002/11/13 00:44:09 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/utility.c,v 1.182 2002/11/15 03:09:38 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -186,7 +186,6 @@ ProcessUtility(Node *parsetree,
CommandDest dest,
char *completionTag)
{
- char *relname;
if (completionTag)
completionTag[0] = '\0';
@@ -702,9 +701,7 @@ ProcessUtility(Node *parsetree,
{
ClusterStmt *stmt = (ClusterStmt *) parsetree;
- CheckOwnership(stmt->relation, true);
-
- cluster(stmt->relation, stmt->indexname);
+ cluster(stmt);
}
break;
@@ -833,8 +830,8 @@ ProcessUtility(Node *parsetree,
switch (stmt->reindexType)
{
+ char *relname;
case INDEX:
- relname = (char *) stmt->relation->relname;
CheckOwnership(stmt->relation, false);
ReindexIndex(stmt->relation, stmt->force);
break;