On 7/01/2012 10:52 PM, Jason Buberel wrote:
I'm considering the migration of an existing large (2.3TB) table to a new tablespace. The table size, according to the '\dt+' command: Maybe you should create a set of partitioned tables in the new tablespace, copy your data over, then drop the old table and rename the partition to the old table's name instead? If the big table keeps on accumulating data (via INSERTs) you can add a trigger that mirrors all updates to the partition while the copy runs. This won't work so well if the big table has UPDATEs and DELETEs too, since you can't delete or update records from a trigger before they've been copied to the new table and committed. -- Craig Ringer |