Reputation: 4242
Is it possible to specify region split values when creating a table in Phoenix with composite primary key? For instance:
CREATE TABLE TEST_TABLE(A VARCHAR, B VARCHAR CONSTRAINT PRIMARY KEY (A,B)) SPLIT ON (1,2)
The above specifies the value for splitting on key A
. How do include a value for B
i.e. I want to split using keys. Is it even possible?
Upvotes: 0
Views: 212
Reputation: 146
Appears to be undocumented, but it works if you nest the split points.
CREATE TABLE TEST_TABLE(A VARCHAR, B VARCHAR CONSTRAINT PRIMARY KEY (A,B))
SPLIT ON (('1', '2'), ('3', '4'))
Upvotes: 0