Reputation: 190
We want to rename old upper-case fieldnames in our mssql db to "Pascal-Case".
Our problem is, there are a lot of dependencies on those columns.
For example:
sp_RENAME 'Object.OBJECTID' , 'ObjectID', 'COLUMN'
When executing the above SQL the following error is returned:
Object 'Object.OBJECTID' cannot be renamed because the object participates in enforced dependencies.
Because we are only change the character case, we do not really break deps. Is there a way to force this operation?
Upvotes: 1
Views: 1652
Reputation: 6568
You have two choices to solve this problem:
Manual Method
Automatic Method
You can simply use third party applications such as ApexSQL and use it's Safe Rename
feature.(Watch the tutorial video here). You can also use RedGate's Smart Rename
fetaure too.(Read more here)
Upvotes: 1