Now XC does not support update of a distribution key. This feature is related to tuple relocation, because changing the key of a distribution column would mean that we can move a tuple from a datanode to another.
Here is a small example:
postgres=# create table aa (a int, b int) distribute by hash (a);
CREATE TABLE
postgres=# update aa set a = 4 where b = 2;
ERROR: Partition column can't be updated in current version
In the test case constraints.sql we have added distribute by replication clause to a number of create table statements to by pass this limitation.
In the test case foreign_key.sql we have added distribute by replication
clause to a number of create table statements to by pass this limitation.