The T-SQL System_User is an security function and return the system user name.
System_User Syntax:
SYSTEM_USER
System_User Example:
select SYSTEM_USER as 'System_user';
System_user |
---|
comp\john |
See also: T-SQL Functions -> CURRENT_USER | ORIGINAL_LOGIN | SESSION_USER | USER_NAME