Way of setting up a shortcut to a database for MS SQL Server Management Studio

shortcutssms

I'd like to have a list of my database servers (I am a developer), I currently have a list of RDP files for different machines I connect to. Is there a similar feature in SQL Server Management Studio that would help me go directly to where I need to go without me having to wait for the login screen to pop up and ask me which server I want?

Best Answer

Yes you can use the following command:

ssms.exe -S SERVERNAME -d DATABASENAME -E

You can either run this using run, or put it into a .txt file and change the extension to .bat and run that.

Some more information can be found by runing smss.exe /?:

Usage:
ssms.exe [-S server_name[\instance_name]] [-d database] [-U user] [-P password] [-E] [file_name[, file_name]] [/?]

    [-S The name of the SQL Server instance to which to connect]
    [-d The name of the SQL Server database to which to connect]
    [-E]    Use Windows Authentication to login to SQL Server
    [-U The name of the SQL Server login with which to connect]
    [-P The password associated with the login]
    [file_name[, file_name]] names of files to load
    [-nosplash] Supress splash screen
    [/?]    Displays this usage information