MYSQL query to reset Administrator's password:
Follow the steps as mentioned below which would help you to reset the "admin"/"administrator" password as "admin".
1. Connect to MySQL Server on Port 33356 using the command from the SC+ server console cmd > cd [SCP Home]\\mysql\\bin cmd> mysql.exe -u root -P 33356 supportcenter
2. Use the following query to reset the "admin" password:
update AaaPassword join AaaAccPassword on AaaPassword.password_id = AaaAccPassword.password_id join AaaAccount on AaaAccPassword.account_id = AaaAccount.account_id join AaaLogin on AaaAccount.login_id = AaaLogin.login_id set PASSWORD='2+uYvE3SLfO3XaHl+CaGLA==', SALT='1103287238602' where name like '%admin%';
MSSQL To find the Administrator logins execute the below query:
select aar.account_id,al.name from aaaauthorizedrole aar left join aaarole ar on aar.role_id=ar.role_id left join aaaaccount aa on aar.account_id=aa.account_id left join aaalogin al on aa.login_id=al.login_id left join aaauser au on al.user_id=au.user_id left join sduser sd on au.user_id=sd.userid where aar.role_id=4 and sd.status='ACTIVE';
Use the below query to reset the "admin" account password, replace the username at the end of this query with the username of the user for whom you would like to reset the password(from the first query result).
update AaaPassword set PASSWORD='2+uYvE3SLfO3XaHl+CaGLA==', SALT='1103287238602' where PASSWORD_ID in ( select AaaPassword.PASSWORD_ID from AaaPassword LEFT join AaaAccPassword on AaaPassword.password_id = AaaAccPassword.password_id LEFT join AaaAccount on AaaAccPassword.account_id = AaaAccount.account_id LEFT join AaaLogin on AaaAccount.login_id = AaaLogin.login_id where name = 'administrator' )
Note : If ' administrator ' name is not present in the application use below queries to update global administrator password
select * from globaladmin
- Will display globaladmin id's in the application
select * from aaalogin
- Will display user id's of globaladmin
*. Use below query to update globaladmin password to ' admin '. Replace user ID with user id present in the table ' aaalogin '
update AaaPassword set password='2+uYvE3SLfO3XaHl+CaGLA==', SALT='1103287238602' where password_id in (select ap.password_id from aaaaccpassword ap left join aaaaccount ac on ac.account_id=ap.account_id left join aaalogin al on al.login_id=ac.login_id where al.user_id=user ID);
Postgres
1.) Execute this query to find built-in Administrator login in the application.
select al.login_id"Login ID",au.first_name"Name",al.name"Login Name" from aaaauthorizedrole aar left join aaarole ar on aar.role_id=ar.role_id left join aaaaccount aa on aar.account_id=aa.account_id left join aaalogin al on aa.login_id=al.login_id left join aaauser au on al.user_id=au.user_id left join sduser sd on au.user_id=sd.userid where aar.role_id=4 and sd.status='ACTIVE';
select * from aaalogin where name='administrator';
Take the User Id from the above query nd pass it in the below update query.
2.) From the output of the first query, identify the right user and use the login_id for that user in the below query(where it is highlighted) to reset his password.
update AaaPassword set password='2+uYvE3SLfO3XaHl+CaGLA==', SALT='1103287238602' where password_id in (select ap.password_id from aaaaccpassword ap left join aaaaccount ac on ac.account_id=ap.account_id left join aaalogin al on al.login_id=ac.login_id where al.user_id=user_id);
Note:After resetting the password, you will be able to login with password as 'admin', provided you select 'Local Authentication' in the "Log on to"drop-downlist.