|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Multiple databasesHi
I need to run a masive script on multiple databases (about 20) I only want to execute the script once to then loop and run on all databases one by one. Is there a clean way of doing so? Thanks create a third party application with dot net
put the server name in array of connection string with in a for-next loop call each connection string and then call the execute method -- Show quotethanks, ------------------------------------ Jose de Jesus Jr. Mcp,Mcdba Data Architect Sykes Asia (Manila philippines) MCP #2324787 "Jaco" wrote: > Hi > > I need to run a masive script on multiple databases (about 20) > I only want to execute the script once to then loop and run on all databases > one by one. Is there a clean way of doing so? > > Thanks Yup
use undocumented sp_MSforeachdb. Google for that Regards R.D Show quote "Jose G. de Jesus Jr MCP, MCDBA" wrote: > create a third party application with dot net > put the server name in array of connection string > with in a for-next loop > call each connection string and then > call the execute method > > -- > thanks, > > ------------------------------------ > Jose de Jesus Jr. Mcp,Mcdba > Data Architect > Sykes Asia (Manila philippines) > MCP #2324787 > > > "Jaco" wrote: > > > Hi > > > > I need to run a masive script on multiple databases (about 20) > > I only want to execute the script once to then loop and run on all databases > > one by one. Is there a clean way of doing so? > > > > Thanks Thanks.
Show quote "R.D" wrote: > Yup > use undocumented sp_MSforeachdb. Google for that > Regards > R.D > > "Jose G. de Jesus Jr MCP, MCDBA" wrote: > > > create a third party application with dot net > > put the server name in array of connection string > > with in a for-next loop > > call each connection string and then > > call the execute method > > > > -- > > thanks, > > > > ------------------------------------ > > Jose de Jesus Jr. Mcp,Mcdba > > Data Architect > > Sykes Asia (Manila philippines) > > MCP #2324787 > > > > > > "Jaco" wrote: > > > > > Hi > > > > > > I need to run a masive script on multiple databases (about 20) > > > I only want to execute the script once to then loop and run on all databases > > > one by one. Is there a clean way of doing so? > > > > > > Thanks thats cool
-- Show quotethanks, ------------------------------------ Jose de Jesus Jr. Mcp,Mcdba Data Architect Sykes Asia (Manila philippines) MCP #2324787 "R.D" wrote: > Yup > use undocumented sp_MSforeachdb. Google for that > Regards > R.D > > "Jose G. de Jesus Jr MCP, MCDBA" wrote: > > > create a third party application with dot net > > put the server name in array of connection string > > with in a for-next loop > > call each connection string and then > > call the execute method > > > > -- > > thanks, > > > > ------------------------------------ > > Jose de Jesus Jr. Mcp,Mcdba > > Data Architect > > Sykes Asia (Manila philippines) > > MCP #2324787 > > > > > > "Jaco" wrote: > > > > > Hi > > > > > > I need to run a masive script on multiple databases (about 20) > > > I only want to execute the script once to then loop and run on all databases > > > one by one. Is there a clean way of doing so? > > > > > > Thanks |
|||||||||||||||||||||||