Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 Altering Column Names

Author  Topic 

ninel
Posting Yak Master

141 Posts

Posted - 2006-08-09 : 13:00:52
I have table Employee. It contains the columns : name, phone, addr1

I would like to change the addr1 column to Address.

How can I do this?

Srinika
Master Smack Fu Yak Hacker

1378 Posts

Posted - 2006-08-09 : 13:06:35
U can do it in several ways. The easiest is by using Enterprise manager -- > drill down to the table --> design --> do the change there. or u can write a script (refer Alter in BOL)

But if the table is being used by other applications / stored procedures / DTS packages ..., those will be affected.

Srinika
Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-08-09 : 13:12:32
you can also use sp_rename system procedure.



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page
   

- Advertisement -