Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

R/3 Lock/unlock users from SCRIPT

Former Member
0 Kudos

Hello,

We use a script to block users the weekends less those necessary for the business, If I want to see the log of the users in the table ush02 or in the transaction S_BCE_68001439, suim...etc Only shows the information of the users blocked across the transactions EWZ5 and SU10 does not show the information of the users blocked and unblocked by the script, Then the information is not real.

Is not never log in SAP that shows the block and unlocks the users across scripts?

SCRIPT

update usr02 set uflag ='64' where mandt='010' and bname not in <users>

Regards

3 REPLIES 3

jurjen_heeck
Active Contributor
0 Kudos

The logs in SUIM you refer to are obviously not logs on table changes. They're application logs.

You could consider to rewrite your script and make it log to the same location the other transactions you mentioned do.

That way you'll have your information in one place.

Besides that, maybe there's a 'more sophisticated' way to programmatically lock your users. You might even find a way that does log to the proper location, like a function module........

There's also an interesting thread in this forum about the values for UFLAG in USR02.

HTH

Jurjen

Former Member
0 Kudos

I ran scripts through SECATT and I do have logs.

Run SECATT select your script->Goto->Logs->search your logs.

I hope this helps.

WolfgangJanzen
Product and Topic Expert
Product and Topic Expert
0 Kudos

I strongly recommend the usage of API functions, such as

- function module BAPI_USER_LOCK

- function module BAPI_USER_UNLOCK

Refrain from updating any DB tables directly !!!