我正在尝试删除并重新创建 sa 帐户来重置密码。
IF EXISTS (SELECT * FROM sys.server_principals WHERE name = N'sa')
DROP LOGIN [sa]
GO
我收到错误
Cannot use the special principal 'sa'.
此外,当我尝试在 SSMS 中重置 sa 密码时,我收到一个错误Cannot alter the login 'sa' because it does not exist or you don't have permission. Error: 15151
答案1
sp_password NULL,'new_password','sa'
go