Change Configuration Options Using a T-SQL Stored Procedure and a .config File

Learn how you can change many configuration options in SQL Server 2005 and SQL Server 2000 simultaneously by using a.config file and a T-SQL stored procedure named sp_ConfigureFromFile.

Karen Bemowski

February 5, 2009

1 Min Read
ITPro Today logo in a gray background | ITPro Today

In SQL Server, there are several ways to change a server's configuration options, but they all have drawbacks. For example, you can use a GUI such as SQL Server 2005's SQL Server Management Studio (SSMS), but you can't use it to programmatically change server configuration options. Alternatively, you can use the sp_configure system stored procedure, but you can change only one configuration option each time you execute sp_configure.

Wanting to programmatically change many configuration options without having to execute sp_configure numerous times, Eli Leiba came up with a different approach: List all the configuration options to be changed in a configuration (.config) file and use a stored procedure to apply those changes. Learn about Eli's technique and download his T-SQL stored procedure, sp_ConfigureFromFile, in the article "Change Many Server Configuration Options in One Fell Swoop."

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like