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.
| Author |
Topic |
|
sunnykj
Starting Member
29 Posts |
Posted - 2005-09-07 : 01:37:21
|
| I want to change one column 's name which have had data in it?Can I? |
|
|
jen
Master Smack Fu Yak Hacker
4110 Posts |
Posted - 2005-09-07 : 01:43:04
|
read sp_rename first in BOL --------------------keeping it simple... |
 |
|
|
sunnykj
Starting Member
29 Posts |
Posted - 2005-09-07 : 01:45:28
|
| Sorry,what is the "BOL"?Online book?:) |
 |
|
|
Kristen
Test
22859 Posts |
Posted - 2005-09-07 : 02:33:27
|
| BoL is books online. Its installed with the SQL Server client tools, so if you have those installed "Books Online" should be in your Start : Programs : Microsoft SQL Server.Using SQL you can rename a column usingEXEC sp_rename 'MyTable.MyColumn', 'NewColumnName'Using enterprise manager you can use the Table Design tool and just type a new name over the top of the old one, it will be "renamed" when you press SAVE.Kristen |
 |
|
|
sunnykj
Starting Member
29 Posts |
Posted - 2005-09-08 : 02:31:58
|
| Thank You very very much! |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2005-09-08 : 02:53:32
|
| Make sure that no application is using that tableOtherwise you may get errors from the application and you need to change there alsoMadhivananFailing to plan is Planning to fail |
 |
|
|
|
|
|