I have the following code to run SSMS from python
script (because I want it to run automatically before I get to work):
import os
run_line = ' '.join(['ssms.exe', '-S', server_name, '-U', user_name, '-P', my_password])
os.system('cmd /c ' + run_line)
Where server_name user_name my_password
hold the arguments for the ssms.exe
running.
It works and starts the SSMS using the user and password, but the script doesn't terminate until I close the SSMS, or shut it down manually.
How can I run the program and end the script automatically without closing the SSMS?