Adding SQL Server Management Studio to a development machine

A quick post in case any of you developers out there are having trouble adding the SQL Server Management Studio tool if you have Visual Studio 2005 with an installation of SQL Server Express Edition 2005.
The setup.exe will fail when it checks your current install, especially if you’ve been applying Windows Updates which may have upgraded your SQL Express Edition database to a later version than is on the SQL Server 2005 CD.
The trick when trying to add the tools is to run the setup.exe with the optional command-line parameter of SKUUPGRADE=1. So open a Command Line window, browse to your CD drive with the SQL Server 2005 disc in it and type:
setup.exe SKUUPGRADE=1
It won’t moan now when it comes to check either the existing edition installed on your machine, or that there may be hidden 2005 Tools already on your machine and not listed in Add/Remove Programs (which I’ve seen in other blog posts).
Hope this helps reduce lost hair from being pulled out!