on 08-05-2008 7:42 AM
hi experts,
i am using 4.7 ides with orcale 8i & want to lock user through command promat level.
i had install data base in D drive..& OS in C drive
i am using following steps and getting problem plz guide me
go to command proamt
then SQLPLUS
then SYSTEM/MANAGER AS SYSDBA
then in SQL> UPDATE USR02 SET UFLAG='64' WHERE BNAME='user id' & MANDT='client no'
then SQL>commit
but it shows only 2
what is this ......
how can i use it.
is there anyone who can slove this problem.
plz help me out.
regards
anuj
thanks a lot all of u
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
After you finish creating this script and getting it to update the db successfully, you'd still have another problem. The table USR02 is buffered which means after you update it via DB back-end, the data may not be updated in the SAP buffers. The SAP user will remain locked and unable to login for a period of time.
You can always manually run /$sync in SAP, but if you are going to do that in the first place - why not just run SU01 to unlock the user?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
i suggest using tp command to do this
tp locksys <sid>
command will lock all the users except sap* and ddic
Samrat
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear Anuj,
Please find the below steps to lock the users in database level(command level),easiest way would be to write a sqlplus command that sets the UFLAG field in table USR02 to 64 EXCEPT for the BNAMEs you don't want locked. When you are done, you can do the same again but change the UFLAG field to 0.
The SQL statement would look like:
update SAPR3.USR02 set UFLAG = 64 where MANDT = <client number> and BNAME != <don't lock user 1>
AND BNAME != <don't lock user 2>;
You can replace != with < > if you want ,run this from an OS command line.
When users are locked, the uflag is set to 64.
so you can try with query to check.:
select bname, uflag from sapr3.usr02 where mandt=<client number>;
Thanks
Kishore
Edited by: Kishore Kumar Tenkayala on Aug 5, 2008 2:18 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Try same sql statement followed by
;
i.e.
UPDATE USR02 SET UFLAG='64' WHERE BNAME='user id' & MANDT='client no';
Commit;
Thanks,
Shambo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.