Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

Execute SQL-DMO Database method on all databases

By Roy Ashbrook,

This script allows you to specify a method and a server (or multiple servers.) It will then execute the method on every database on the server. With very minor tweaking you could have it search for the servers, then call the server db script with each one, or add another nesting to call tables or whatever other object you like. You could even switch up the eval statements a little and call a generic object/method caller. Tested on sql2k with just a few databases.

Total article views: 651 | Views in the last 30 days: 7
 
Related Articles
FORUM

Render method not returning any data

ReportExecution2005 web server render method

BLOG

Goodness-of-Fit Testing with SQL Server, part 1: The Simplest Methods

By Steve Bolton …………In the last series of mistutorials I published in this amateur SQL Server blog,...

ARTICLE

The Scientific Method: a call to action

Gail Shaw issues a rallying call for the SQL Community to adopt the Scientific Method when investiga...

FORUM

Best Encryption method

Is it a good method of encryption?

FORUM

Simple value method help

How to return text contents to .value method?

Tags
 
Contribute