Answer Posted / vishal
Rename a table using sp_rename
sp_rename <Old Table Name>, <New Column Name>
Rename a column using sp_rename
here as third argument we have to provide column. default
third argument for sp_rename is table.
sp_rename <table name>.<old Column Name>, <New Column Name>,
'column'
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is repeatable read?
What is importing utility?
What are the purposes and advantages stored procedure?
What is the use of sql profiler in sql server 2012?
What are the different types of backups avaialabe in sql server 2005?
Where is trigger in sql server?
Can one drop a column from a table?
Tell me about builtinadministrator?
what is an extended stored procedure? Can you instantiate a com object by using t-sql? : Sql server database administration
What command do we use to rename a db, a table and a column?
How do I manually uninstall an instance of sql server 2016?
Data is not being delivered to subscribers, what can be the possible reasons? : sql server replication
What is use of except clause? How does it differ from not in clause?
What is the maximum size of column in sql server?
System variable and temporary variables