alter table modify column data type mysql code example
Example 1: alter table column change data type to text mysql
ALTER TABLE tablename MODIFY columnname INTEGER;
Example 2: postgresql change column type
ALTER TABLE assets ALTER COLUMN name TYPE VARCHAR;
Example 3: get the mysql table columns data type mysql
SHOW COLUMNS FROM mydb.mytable;
Example 4: update column data type postgres
ALTER TABLE table_name
ALTER COLUMN column_name [SET DATA] TYPE new_data_type;