cancel
Showing results for 
Search instead for 
Did you mean: 

SAP* locked!Unlocking from DB level says unknown table USR02

Former Member
0 Kudos

Hi,

The user SAP* is locked.

I tried to unlock it at DB(MAXDB) by query:

sql_execute update <db_schema>.USR02 set UFLAG=0 where BNAME='SAP*' and MANDT=u2019000u2019

It says:

ERR

-24988,ERR_SQL: SQL error

-4004,Unknown table name:USR02

Anything can be done here to unlock the SAP* user?

Thanks in advance!

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

i have a couple suggestions

be sure to type the schema directly, not use the parameter as it might be substituted incorrectly

try to use the quotes with "<db_schema>.USR02" or '<db_schema>.USR02 '

i have had this problems with oracle DB once and it worked

btw, i am having the same problem on SQL DB, so i would monitor this thread (i just was able to remember the DDIC password and unlock SAP* from SAP)

Former Member
0 Kudos

Thanks a lot!! But, the problem is not solved.

It till says USR02 table unknown

Former Member
0 Kudos

From the DB server logged in as <sid>adm, run the script below.

sqlcli -U DEFAULT "select * from usr02 where mandt='000' and bname='SAP*'"

Answers (4)

Answers (4)

Former Member
0 Kudos

This error will comes when you are not selecting the correct schema for table

Check it out whether you are using correct db schema from dba_segment,

by using

select owner from dba_segments where segment_name like u2018%SAP%u2019;

than run

update <db schema>.USR02 set UFLAG = 0 where MANDT = '000' and BNAME = u2018SAP*u2019;

than verify it

select bname, uflag from sapr3.usr02 where mandt like '000';

Former Member
0 Kudos

Hi All!!!!

Thnaks to all of you who helped me.

The problem was I was usign the wrong user and running the queries.

Though we log on with <SID>adm,we will need to swithc to that particular DB

user to run the queries.

Finally it worked!!!!

Once again thanks to everyone.

Sushma

Former Member
0 Kudos

Hi,

I think correct schema name is not used in your sql commands. Could you please cross check the schema name with environment variables. You can get the correct schema name from environment variable dbs_ora_schema.

Hope this helps.

Manoj

Former Member
0 Kudos

Hai,

Check the below link.....

Regards,

Yoganand.V

Former Member
0 Kudos

Below are 2 scripts that will a) show the status of a user and b) unlock that user.

Note, this was used in MSSQL.

--This script is used to determine the status of users in a system,

--the codes are as follows:

--0 --> not locked

--32 --> globally locked by administrator

--64 --> locally locked by administrator

--128 --> locked due to incorrect loggins

Use '<SID>'

go

setuser '<sid>'

go

select * from USR02

To unlock a user execute the script below.

Update USR02 set UFLAG=0 where BNAME = '<USER>' and MANDT = '<CLIENT>'