Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Updating multiple databases

Status
Not open for further replies.

hross2026

Programmer
Nov 11, 2003
7
US
Hello,

I'm writing to see if anyone is familiar with a tool that can update SQL Server code (i.e. stored procedures, views or table modifications) throughout multiple databases. Currently we use Query Analyzer to step through every database and run the code that's being added/edited. As the number of our databases grows, it will not be an easy task to make a change to a stored procedure for example throughout every database. It would be much easier to select from a list of available databases that need to be updated with the change. Is there such a tool out there? If so, can someone fill me in?

Thanks.
 
You can use osql to update each database from a script. Just have th list of databases/servers in a table, keep all the scripts on disc and call osql for each.

Could also use dmo to copy the SPs from a master database in a similar way
see

======================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top