Using sp_configure to read or write the configuration file

The syntax for using the configuration file option with sp_configure is:

sp_configure "configuration file", 0, "subcommand", "file_name"

where:

Examples

Example 1 Performs validation checking on the values in the file srv.config and reads the parameters that pass validation into the server. Current run values are substituted for values that do not pass validation checking:

sp_configure "configuration file", 0, "read", "srv.config"

Example 2 Creates the file my_server.config and writes the current configuration values the server is using to that file:

sp_configure "configuration file", 0, "write", "my_server.config"