aboutsummaryrefslogtreecommitdiff
path: root/src/include/commands/cluster.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/commands/cluster.h')
-rw-r--r--src/include/commands/cluster.h13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/include/commands/cluster.h b/src/include/commands/cluster.h
index 401a0827aec..a941f2accda 100644
--- a/src/include/commands/cluster.h
+++ b/src/include/commands/cluster.h
@@ -19,15 +19,18 @@
#include "utils/relcache.h"
+/* flag bits for ClusterParams->flags */
+#define CLUOPT_RECHECK 0x01 /* recheck relation state */
+#define CLUOPT_VERBOSE 0x02 /* print progress info */
+
/* options for CLUSTER */
-typedef enum ClusterOption
+typedef struct ClusterParams
{
- CLUOPT_RECHECK = 1 << 0, /* recheck relation state */
- CLUOPT_VERBOSE = 1 << 1 /* print progress info */
-} ClusterOption;
+ bits32 options; /* bitmask of CLUOPT_* */
+} ClusterParams;
extern void cluster(ParseState *pstate, ClusterStmt *stmt, bool isTopLevel);
-extern void cluster_rel(Oid tableOid, Oid indexOid, int options);
+extern void cluster_rel(Oid tableOid, Oid indexOid, ClusterParams *params);
extern void check_index_is_clusterable(Relation OldHeap, Oid indexOid,
bool recheck, LOCKMODE lockmode);
extern void mark_index_clustered(Relation rel, Oid indexOid, bool is_internal);