Cancel Query in remote ssms from ssms in my pc We connect to our customer's database server with vpn. Sometimes we manage Sql server to connect database server or to connect with ssms in our pc's. 
I executed a query with ssms in database server, then the connection has gone down. I have tried to connect many times but failed. I have to cancel this query. 
I can connect with ssms in my pc's.
Can I cancel query with ssms in my pc?
Step 1:  Get query session id using below query

SELECT sqltext.TEXT,
req.session_id,----- SPID
req.status,
req.command,
req.cpu_time,
req.total_elapsed_time,req.start_time,db_name(database_id) DatabaseName
FROM sys.dm_exec_requests req
CROSS APPLY sys.dm_exec_sql_text(sql_handle) AS sqltext
where [status] &lt;&gt; 'background'
and command&lt;&gt; 'TASK MANAGER'




Step 2: use kill command to kill the process execution

Kill(53) -- KIll (SPID)