SUSER_SID returns the security identification number (SID) for the specified user's login name.
SUSER_SID can be used as a DEFAULT constraint in either ALTER TABLE or CREATE TABLE.
Syntax of SUSER_SID Function :
SUSER_SID ( [ 'login' ] )
login is a user's login name. It is a sysname. It is an optional. If you don't specify then it returns information about current user.
Return type of SUSER_SID is a varbinary(85).
Examples of SUSER_SID Function :
Example 1 : Use of SUSER_SID function in select clause
SELECT SUSER_SID ('NorthwindUser')
Output
0x0105000000000005150000007D3F02A2B97927CFBCECB55FE8030000
Above example returns security id number for specified user's login name.