Changing data types by dropping and re-creating the table
Some changes to a table cannot be made with the ALTER TABLE statement.
About this task
For example, you must make the following changes by redefining
the column (that is, dropping the table and then re-creating the table
with the new definitions):
- An original specification of CHAR (25) to CHAR (20)
- A column defined as INTEGER to SMALLINT
- A column defined as NOT NULL to allow null values
- The data type of an identity column
Procedure
To change data types: