rajeevnandanmishra
Programmer
Suppose i have a table with following definition.
CREATE TABLE myTable (col1 Int, col2 Varchar(10))
Now I want to add one more column colX (datetime) in between col1 & col2. So the new table structure should be like
col1 Int, colX Datetime, col2 Varchar(10)
Previously, i was doing this by backing up the table and then deleing the old table, creating a new one and then inserting the records from the backup table.
Can i do the same thing with Alter Table statement or any other method which does not need to take the backup/ droping of existing table.
All helps are highly appreciated.
Rajeev
CREATE TABLE myTable (col1 Int, col2 Varchar(10))
Now I want to add one more column colX (datetime) in between col1 & col2. So the new table structure should be like
col1 Int, colX Datetime, col2 Varchar(10)
Previously, i was doing this by backing up the table and then deleing the old table, creating a new one and then inserting the records from the backup table.
Can i do the same thing with Alter Table statement or any other method which does not need to take the backup/ droping of existing table.
All helps are highly appreciated.
Rajeev