Finding Session Id in MS SQL User's Current Process

In MS SQL, the following query is run to find the Session Id of the logged in user in the current process.

SELECT @@SPID AS 'SessionId'


You May Interest

Using MS SQL If Else

What is CHECKPOINT Process in the SQL Server ?

Deleting Columns From a Table with a Query in MS SQL

What is the Difference Between VARCHAR and VARCHAR(MAX) Datatypes ...

Which TCP/IP Port Does the SQL Server Run On ?