#16 Unsafe ALTER TABLE DISTRIBUTE operation

Undecided
closed
nobody
None
1
None
nobody
2014-06-17
2014-06-10
No

In general case ALTER TABLE DISTRIBUTE basically copies table data to a store, then truncates table, then copies data back according to new distribution.
If last operation fails, all table data are lost.

Proposed approach: internally create new table, copy over data, drop old table and rename new to the old name.
Or maybe a low-level approach: copy data to the new pages (files) and wire them up to the existing pg_class instance.

Discussion

    • status: open --> closed
     
  • There was unmatched put/get read/write functions handling the format of the tuple store.

    8670a56e8909ebfc597c5b74422baa3f9935c418
    c8a96a6e107086edf1aa1ca002fe4f235c7620ec