The only way I know to change the order of the columns in a table is by dropping the table and recreating it with the columns in the proper order. Is there another way in SQL Server 2005 that is easier?
First of all, why do you want it? How does the order of columns in the tables matter? When you write your SQL Query you should list out the column names in the order you want for your application. The order of columns in the table should not matter.
It doesn't matter to me. However, I have a developer who is making a lot of noise (very loudly) and management wants me to do it to quiet him.
[quote user="lcerni"] It doesn't matter to me. However, I have a developer who is making a lot of noise (very loudly) and management wants me to do it to quiet him. [/quote] He should be fired.
Ask him to come here for a nice smack in this case [], http://www.databasejournal.com/features/mssql/article.php/1436301 fyi.
As said, ordinal posotion of the columns doesnt matter. In the front end, dont use Rs(0), Rs(1),.... Instead use Rs("column_name1"),Rs("column_name2"),.... where Rs is a RecordSet object
Add the column to the table at the "end" and create a view for the developer in which you can mimic the ordinal positions that guy "requests" and have him access the view instead of the base table. That procedere offers many advantages apart from this one.