Sql-server – SSMS: Where does SQL Server store its server names

sql serverssms

I have a number of "old" servers or server names with a typo in them that keep showing up in my dropdown list of server in the "Connect to Database" dialog of SQL Server Management Studio:

enter image description here

Where are those names stored?? Is there any way to clean up that list and remove some entries??

Best Answer

For SQL 2005:

C:\Documents and Settings\<USER>\Application Data\Microsoft\Microsoft SQL Server\90\Tools\Shell\mru.dat

For SQL 2008:

C:\Documents and Settings\<USER>\Application Data\Microsoft\Microsoft SQL Server\100\Tools\Shell\SqlStudio.bin

Microsoft SQL Server Management Studio 12.0

c:\Users\<USER>\AppData\Roaming\Microsoft\SQL Server Management Studio\12.0\SqlStudio.bin

Microsoft SQL Server Management Studio 14.0.17289.0

c:\Users\<USER>\AppData\Roaming\Microsoft\SQL Server Management Studio\14.0\SqlStudio.bin

Microsoft SQL Server Management Studio 18:

C:\Users\%username%\AppData\Roaming\Microsoft\SQL Server Management Studio\18.0\UserSettings.xml

So...

  1. Shut down all instances of SSMS
  2. Delete/Rename the file
  3. Open SSMS

Edit: on MS Connect https://connect.microsoft.com/SQLServer/feedback/details/424800