Skip to Content
avatar image
Former Member

Unlock user id via sql(oracle) command

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

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Feb 15, 2013 at 06:38 PM

    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.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 12, 2012 at 05:31 AM

    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

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      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

  • Mar 12, 2012 at 12:01 PM

    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

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      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