How to modify column length?


(Jason shi) #1

Because of business reasons, we need to increase the table column from string (100) to string (200), I did not find how to modify it in online documents, how can I do it?
Thanks a lot!


(Raphael 'kena' Poss) #2

This is a new feature in CockroachDB 2.1. Try:

ALTER TABLE yourtable ALTER COLUMN yourcolumn TYPE STRING(200);

Does this work?


(Jason shi) #3

Thanks for your answer!
My db current version is v1.1.4,i’ll try it after upgrade.