I need to increase the size of a character varying(60) field in a postgres database table without data loss.
I have this command
alter table client_deta
Referring to this documentation, there would be no data loss, alter column
only casts old data to new data so a cast between character data should be fine. But I don't think your syntax is correct, see the documentation I mentioned earlier. I think you should be using this syntax :
ALTER [ COLUMN ] column TYPE type [ USING expression ]
And as a note, wouldn't it be easier to just create a table, populate it and test :)