Session ID - SQL Server
The following SQL statement will return the current session ID.
SELECT session_id FROM sys.dm_exec_requests where sql_handle is not null