0% found this document useful (0 votes)
494 views2 pages

How To Mass Lock / Unlock in Sap With SQL User Command How To Mass Lock

This document provides instructions for mass locking and unlocking SAP users using SQL commands. It describes how to mass lock users by updating the UFLAG field in the USR02 table to 64. It also provides two options for mass unlocking users - unlocking specific users by name or unlocking all users by setting the UFLAG field to 0 for all users.

Uploaded by

Shafeeq Mohammed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
494 views2 pages

How To Mass Lock / Unlock in Sap With SQL User Command How To Mass Lock

This document provides instructions for mass locking and unlocking SAP users using SQL commands. It describes how to mass lock users by updating the UFLAG field in the USR02 table to 64. It also provides two options for mass unlocking users - unlocking specific users by name or unlocking all users by setting the UFLAG field to 0 for all users.

Uploaded by

Shafeeq Mohammed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

HOW TO MASS LOCK / Unlock in SAP with SQL USER COMMAND

HOW TO MASS LOCK / Unlock in SAP with SQL USER


COMMAND
HOW TO MASS LOCK
Execute this SQL command

update SID.USR02 set UFLAG = 64 Where MANDT = '110' and BNAME = 'SAP *';

Explain:

BNAME! = 'SAP *' means clustering lock everyone except SAP *

UFLAG = 64 means clustering lock

Alternately, try the below SQL command:

use HRS
UPDATE [hrs]. [USR02]
SET UFLAG = '64'
WHERE (UFLAG = '0')
AND NOT (BNAME like SAP% GOLD BNAME = 'DDIC' OR BNAME = 'TMSADM'
OR BNAME like J2EE% GOLD BNAME like '% SLD GOLD BNAME =' JCO_DATA '
BNAME OR = 'BASIS_ADMIN')
================================================== ==================================================
========

HOW TO UNLOCK MASS WITH USER SQL COMMAND


Unlock support team:

update sid.USR02 set UFLAG = 0 Where MANDT = '110' and BNAME in ( 'DDIC' SAP * ', ' ALEREMOTE ' '

WF-BATCH ' ' TMSADM ' ' ITOUSER ' ' SAPCPIC ' ' SAPJSF ' ' J2EE_ADMIN ' ' J2EE_GUEST ' SAP CLERK' )

OR May you unlock all user with Unlock user:

update sid.USR02 set UFLAG = 0 Where MANDT = '110'

You might also like