cancel
Showing results for 
Search instead for 
Did you mean: 

Unlock user id via sql(oracle) command

Former Member
0 Kudos

Hi experts,

I update the uflag in usr02 table oracle command to unlock the user in ecc 6.0

Update sapsr3.usr02 set uflag=0 where mandt=200 and bname='vivek'

commit

but login not possible.

if there is any method to unlock user via OS  and database level.

Ecc 6.0

Oracle 10g on RHEL 5.3

Regards,

Vivek

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member

Hi Vivek

After giving the sql command, give commit.

Otherwise it doesn't save until you log out of sql command prompt, and at times, not even then.

georgi_k
Explorer
0 Kudos
I wish I had seen this advice earlier.Loggin out of sql promt is what I was missing.
JPReyes
Active Contributor
0 Kudos

Instead of,

Update sapsr3.usr02 set uflag=0 where mandt=200 and bname='vivek'

Use

update SAPSR3.USR02 set uflag='0' where bname='VIVEK' and mandt=200;

I just tested that and worked fine, that should unlock your user

Regards

Juan

Former Member
0 Kudos

Thanks Juan,

after unlock via this sql command try to login this user.

i m sure you can't login.


JPReyes
Active Contributor
0 Kudos

I can, I already test it, check your sql statement and try again.

Regards, Juan

Former Member
0 Kudos

Hi Vivek,

Juan can login because the statement is correct.

Your problem may be, that your user was not locked "manually" (SU01 or SU10) but by too many failed logon attempts. As far as I remember, this method won't work then.

If you have time, you may trace SQL statements on Oracle level and lock another user with "failed logon attempts" - then you should see which tables are involved and which updates were issued.

If you are the SAP basis administrator, get in via parameter / restart / SAP* deletion, create SAP* again, then create an authorized administration user and store the complex password in a safe place (for emergency cases like this).

If you are not the SAP basis administrator, I would ask you to contact the admin to unlock your user.

Regards, Peter

Former Member
0 Kudos

Hi,

after providing the above sql statemnet , did it gave the message as "one row updated"?

if not your sql statement has not executed.

you can delete sap* at OS level from sqlplus using below sql statement and then you can unlock and reset your user at ABAP end using newly created sap* user with password pass.

sqlplus> delete from <schema>.usr02 where bname='sap*' and mandt=<CLNT>;

Regards,

Venkata S Pagolu

Former Member
0 Kudos

thanks i khow this solution but for this you have restart the sap instace via changing the parameter in sap profile.

and after exective this command 1 row updated message had come after that i commit.

any other method with out restart sap instance.

Former Member
0 Kudos

Hi,

I think there is no any other option from OS level to reset the password for SAP user. Only thing is to contact your SAP security admin and get the password reset for your user.

Regards,

Venkata S Pagolu