sherifffruitfly (sh*************@gmail.com) writes:
I'm tasked with adding a few fields to our database, and all of the
stuff that goes along with it (updating c# UI code, etc.). The
database is a few hundred tables, with all of the procs, logic code,
etc. that goes along with it.
The consequences (i.e. what breaks) of adding a new field should be
largely predictable from the current structure, along with the fields
to be added. Anybody know of a tool that will tell me this? Or do I
need to just ctrl-f (search) my way through the table names, and do
this manually?
If you only add nullable columns, nothing should break, at least not
if the application is coded properly.
If you add columns that are not null and without a default value, or if you
drop or rename column, you will of course have to find out where to change
things.
Provided that you have all source code on files (include the stored
procedures), you can search all files at once with a tool that can search
in files. Many text editors provide this capability, for instance TextPad.
If you have all your table reference in stored procedures, you can search
directly in SQL Server, but this is a little tricky if you are on SQL 2000.
On SQL 2005 you can search the object_definition column in sys.sql_modules.
--
Erland Sommarskog, SQL Server MVP,
es****@sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pro...ads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinf...ons/books.mspx