Open SSMS With a Different User

When dealing with SQL Server within a corporate setting, there might be instances where connecting to the server requires the use of a different Domain User account. This scenario is common, especially when testing access and permissions for newly created SQL Server AD Users.

While connecting to SQL Server with an alternative Domain User can pose challenges, this guide aims to simplify the process for you.

Connect to SQL Server with Another AD User

Locate the SQL Server Management Studio (SSMS) application icon by using the Windows button. Then:

  • Hold down the CTRL key and right-click the SSMS app icon.
  • Select “Run As Different User”.
Open SSMS as another user

Enter the credentials for the desired Domain User in the prompt.

Run SQL as different user

SSMS will open using the login credentials you provided. Even though the connection window may display an incorrect Domain, rest assured that SSMS will establish a connection with the intended AD User account.

SSMS Connect as Other User

Open SSMS as Another User with a Command

Another method to open SSMS with a different Domain User involves executing the command below in your Windows Terminal. Be sure to customize the Domain and Username before running this command.

C:\Windows\System32\runas.exe /user:domain\username /netonly "C:\Program Files (x86)\Microsoft SQL Server Management Studio 19\Common7\IDE\Ssms.exe"
Run SSMS as Different User (Command)

You can save the above command to a shortcut file, making it convenient for repeated use, and it should work seamlessly if you are utilizing the latest version of SSMS. As of January 2024, the specified directory should accurately point to the SSMS executable (SSMS v19).

I trust that this guide has facilitated a smooth setup for you today!

Leave a Reply

Your email address will not be published. Required fields are marked *