I have a very simple table namely:
CREATE TABLE test(
id INT PRIMARY KEY DEFAULT unique_rowid()
)
And I want to change id
type to bytes so that I can SET DEFAULT uuid_v4();
.
However if I run this sql:
ALTER TABLE test MODIFY id bytes;
I'm getting an error:
pq: cannot convert INT8 to BYTES
Is there a possibility to alter table column from one type to another in cockroachdb?