Check out example codes for "postgresql change column type". It will help you in understanding the concepts better.

Code Example 1

ALTER TABLE assets ALTER COLUMN name TYPE VARCHAR;

Code Example 2

ALTER TABLE table_name
ALTER COLUMN column_name [SET DATA] TYPE new_data_type;
 

Learn ReactJs, React Native from akashmittal.com