Find and Replace in SQL Server 2008

Our company name just changed from CAS to CAC.. I need to update my SQL Server database to reflect the changes. I do not need to update the data in the tables, only the column names, stored procedures, jobs, triggers etc...Does anyone know of a good free script I can use to accomplish this?
LVL 1
cheryl9063Asked:
Who is Participating?
 
rbeadieConnect With a Mentor Commented:
You can just write your own script to autogenerate the SQL based on the metadata (see attached).

But as angellll says, it may just not be worth the effort, as you will also need to ensure that any code or application that also uses the database(s) and objects is updated as well.
q4expertechange.txt
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
renaming the column/table names?
i would NOT do that ...
just not worth the effort, as the names are not visible in the client applications ...
0
 
ProjectChampionCommented:
You're asking for trouble my friend. Even when you do it manually all sort of things can go wrong, think about referential integrities, indexes, dependent objects, permissions, dynamic sql code outside the DB (i.e. in applications)... it's simply not worth it.

Instead of crashing everything and then spending the next couple of weeks trying to find and fix all the bugs, I'd suggest you focus on updating only the page/column titles in the reports and get the job done by the end of the day. You may need to use a bit of diplomacy to convince the stakeholders that it's a big waste of time and effort. I'm sure with the changes currently going on in your organisation; there are a lot of more productive ways to spend your time and effort.
0
 
cheryl9063Author Commented:
Thanks!
0
All Courses

From novice to tech pro — start learning today.