Welcome to MSDN Blogs Sign in | Join | Help

SqlScriptListInstaller

The last of a series of SQL Server-related database Installers is a little helper that simply makes it easier to bundle several SQL scripts together as part of a single Installer package. Instead of mixing several SqlScriptInstallers together with other Installers, you can group them together in a single container:

public class SqlScriptListInstaller : Installer
{
    public SqlScriptListInstaller(
        IEnumerable<SqlScriptInstaller> scriptInstallers)
    {
        foreach (SqlScriptInstaller scriptInstaller
            in scriptInstallers)
        {
            this.Installers.Add(scriptInstaller);
        }
    }
}

This Installer simply holds a list of SqlScriptInstallers in its Installers property. When Install is called, the Install method will be invoked on each of the contained Installers; likewise for Uninstall.

This is in no way the most essential of the three SQL Server-related Installers, but is still a nice convenience at times.

Published Tuesday, December 11, 2007 11:01 PM by ploeh

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

# MSDN Blog Postings &raquo; SqlScriptListInstaller

Tuesday, December 11, 2007 7:57 PM by MSDN Blog Postings » SqlScriptListInstaller

# Data Access Component Testing Redux

Thursday, January 31, 2008 9:42 AM by ploeh blog

About a year ago, I wrote about data access component testing using a custom helper class for setting

# Data Access Component Testing Redux

Thursday, January 31, 2008 10:35 AM by Noticias externas

About a year ago, I wrote about data access component testing using a custom helper class for setting

Leave a Comment

(required) 
required 
(required) 
 
Page view tracker