How to perform a command line installation of SQL Server 2005

I was asked by a customer a while back about available options for performing silent installation of SQL Server 2005 Express Edition. I haven't had a lot of time to research this issue, and the only steps I knew were the ones used by Visual Studio setup to install SQL Express.

Now that I looked into this scenario a bit more, I found an MSDN document entitled How to: Install SQL Server 2005 from the Command Prompt that provides in-depth instructions regarding supported command line switches for SQL 2005 setup and steps for creating an automated installation answer file.

The instructions in this document will allow you to perform all of the following configuration tasks, plus several more that I didn't list:

  • Install a standalone SQL instance
  • Install a clustered SQL instance
  • Rebuilding SQL databases
  • Add/remove individual components
  • Add/remove nodes in a cluster
  • Uninstall a standalone SQL instance
  • Uninstall a clustered SQL instance

Please note that these instructions are generic and apply to all versions of SQL Server 2005. Some of the advanced configuration options are not supported by SQL Server 2005 Express Edition, so you will need to make sure to only attempt to install the Express Edition using switches and options that it supports.