0
When I use ADD can I choose position in columns where it will be adding?
2 Respostas
+ 2
Depends on the RDBMS. Many require you to drop, recreate, and reload the table because the order of the columns may be leveraged in other places of the RDBMS (e.g. if it were used in a hashing algorithm to distribute table rows across a table using a unique key)
+ 1
You can do that using the AFTER keyword, when using MySQL. For example: ALTER TABLE tablename ADD columnname INT AFTER anothercolumn
But it wont work for MSSQL Server. For MSSQL Server you need to recreate the whole table.