July 24, 2012 at 9:14 pm
Comments posted to this topic are about the item Rename column
July 24, 2012 at 9:22 pm
Good question PravS.. Its a new information to me.. I could also look at what cause when other fields renames.. Thankzz..
July 24, 2012 at 10:31 pm
PravS (7/24/2012)
Comments posted to this topic are about the item <A HREF="/questions/Database/91763/">Rename column</A>
I know the answer, but my question is, why a computed column can't be renamed? What's stopping it.
Respected Seniors \ Veterans ,need your views here.
July 24, 2012 at 10:39 pm
Though I got this correct, but I always thought you cannot remane (only) participating columns. Nice question 🙂
~ Lokesh Vij
Link to my Blog Post --> www.SQLPathy.com[/url]
Follow me @Twitter
July 24, 2012 at 10:48 pm
One more thing: If I try to execute this code, why I am getting the error message two times?
Caution: Changing any part of an object name could break scripts and stored procedures.
Msg 4928, Level 16, State 1, Procedure sp_rename, Line 547
Cannot alter column 'Col3' because it is 'COMPUTED'.
Caution: Changing any part of an object name could break scripts and stored procedures.
Msg 4928, Level 16, State 1, Procedure sp_rename, Line 547
Cannot alter column 'Col3' because it is 'COMPUTED'.
Msg 0, Level 20, State 0, Line 0
A severe error occurred on the current command. The results, if any, should be discarded.
~ Lokesh Vij
Link to my Blog Post --> www.SQLPathy.com[/url]
Follow me @Twitter
July 24, 2012 at 11:05 pm
Yes, i have seen it....but i do not know what's happening internally
July 25, 2012 at 1:28 am
You can't rename a PERSISTED computed column, too!
Why?
July 25, 2012 at 1:40 am
This was removed by the editor as SPAM
July 25, 2012 at 3:31 am
Does seem a strange rule, good question thx
_____________________________________________________________________
[font="Comic Sans MS"]"The difficult tasks we do immediately, the impossible takes a little longer"[/font]
July 25, 2012 at 4:42 am
Nice question. Thanks for a new bit of knowledge about Rename.
July 25, 2012 at 6:52 am
Thanks for the question!
I don't use computed columns often, so this is very good to know!
July 25, 2012 at 7:00 am
sestell1 (7/25/2012)
Thanks for the question!I don't use computed columns often, so this is very good to know!
+1. I don't use them that often either, so I learned something today. Thanks for the great question.
July 25, 2012 at 7:14 am
Nice straight forward question. Keep them coming Pradeep.
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
July 25, 2012 at 8:01 am
sestell1 (7/25/2012)
Thanks for the question!I don't use computed columns often, so this is very good to know!
+1
Jason...AKA CirqueDeSQLeil
_______________________________________________
I have given a name to my pain...MCM SQL Server, MVP
SQL RNNR
Posting Performance Based Questions - Gail Shaw[/url]
Learn Extended Events
Viewing 15 posts - 1 through 15 (of 27 total)
You must be logged in to reply to this topic. Login to reply