
The “sa” user is the default user created during the Microsoft SQL Server installation. You must always disable or rename the “sa” user before handing the system to the operation team.
So, how do you check if the “sa” user is renamed or disable.
Execute the following command line,
SELECT name, sid, is_disabled FROM sys.server_principals WHERE principal_id = 1;

From the above screenshot, if the name is showing other than “sa”, it means the “sa” user has been renamed. In this example, it has been renamed to “opersys”. The “is_disabled” value 1 means that the user is in disabled state, means you cannot use this user to login.
Alternatively, use below command (no disabled status will be shown)
SELECT * FROM sys.syslogins WHERE sid = 0x01


