how to rename the table
Answers were Sorted based on User's Feedback
Answer / rajkumar
SP_RENAME 'OLDTABLE NAME', 'NEW TABLE NAME'
eg:
SP_RENAME 'TBL_EMPLOYEE', 'TBL_EMP'
Is This Answer Correct ? | 11 Yes | 3 No |
Answer / 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 |
Answer / mohan
Rename a table
This example renames the customers table to custs.
EXEC sp_rename 'customers', 'custs'
B. Rename a column
This example renames the contact title column in the
customers table to title.
EXEC sp_rename 'customers.contacttitle', 'title', 'COLUMN'
Is This Answer Correct ? | 0 Yes | 2 No |
Why Do you want to work in this company?
1 01 101 01010
What is used to replicate sessions between instances in coldfusion clusters?
How to get last system shutdown time in Sql server when restarted system?
Do you know the different ddl commands in sql?
How to make a column nullable?
How to compose an inquiry to demonstrate the points of interest of an understudy from students table whose name begins with k?
What are orphan records?
What is the difference between writing data to mirrored drives versus raid5 drives
Is candidate a key?
What is a transact-sql statement?
wat is mean by trigger?.......normally wat use......when trigger used in sql........... plz cleary say with example.......