summaryrefslogtreecommitdiff
path: root/src/include/commands/cluster.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2004-05-05 04:48:48 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2004-05-05 04:48:48 +0000
commit077db40fa1f3ef93a60d995cc5b2666474f81302 (patch)
tree911e14b79a368b10ad9fc267fa69f299e86b15f9 /src/include/commands/cluster.h
parent3e3cb0a14a608bb058407b6349c3c9e2d09e13b8 (diff)
ALTER TABLE rewrite. New cool stuff:
* ALTER ... ADD COLUMN with defaults and NOT NULL constraints works per SQL spec. A default is implemented by rewriting the table with the new value stored in each row. * ALTER COLUMN TYPE. You can change a column's datatype to anything you want, so long as you can specify how to convert the old value. Rewrites the table. (Possible future improvement: optimize no-op conversions such as varchar(N) to varchar(N+1).) * Multiple ALTER actions in a single ALTER TABLE command. You can perform any number of column additions, type changes, and constraint additions with only one pass over the table contents. Basic documentation provided in ALTER TABLE ref page, but some more docs work is needed. Original patch from Rod Taylor, additional work from Tom Lane.
Diffstat (limited to 'src/include/commands/cluster.h')
-rw-r--r--src/include/commands/cluster.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/include/commands/cluster.h b/src/include/commands/cluster.h
index 72295803abb..5474fdd5490 100644
--- a/src/include/commands/cluster.h
+++ b/src/include/commands/cluster.h
@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
* Portions Copyright (c) 1994-5, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/commands/cluster.h,v 1.20 2003/11/29 22:40:59 pgsql Exp $
+ * $PostgreSQL: pgsql/src/include/commands/cluster.h,v 1.21 2004/05/05 04:48:47 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -20,5 +20,9 @@
extern void cluster(ClusterStmt *stmt);
extern void rebuild_relation(Relation OldHeap, Oid indexOid);
+extern Oid make_new_heap(Oid OIDOldHeap, const char *NewName);
+extern List *get_indexattr_list(Relation OldHeap, Oid OldIndex);
+extern void rebuild_indexes(Oid OIDOldHeap, List *indexes);
+extern void swap_relfilenodes(Oid r1, Oid r2);
#endif /* CLUSTER_H */