パスワードを別のものに変更する必要がuserid
あります。username
encrypted password
password format
asp.net メンバーシップで SQL 経由でパスワードを変更するにはどうすればよいですか?
パスワードを別のものに変更する必要がuserid
あります。username
encrypted password
password format
asp.net メンバーシップで SQL 経由でパスワードを変更するにはどうすればよいですか?
このクエリを使用できます。
Declare @UserName NVarChar(30)
Declare @Password NVarChar(30)
Declare @Application NVarChar(255)
Declare @PasswordSalt NVarChar(128)
set @UserName = 'UserName'
set @Password = 'Pass'
set @Application = '/Application'
Set @PasswordSalt = (SELECT TOP 1 PasswordSalt FROM aspnet_Membership WHERE UserID IN (SELECT UserID FROM aspnet_Users u, aspnet_Applications a WHERE u.UserName=@UserName and a.ApplicationName = @Application AND u.ApplicationId = a.ApplicationId))
Exec dbo.aspnet_Membership_ResetPassword @Application, @UserName, @Password, 10, 10, @PasswordSalt, -5