Thanks for the response. My requirement is as follows.
We don’t have any locks on the program.
1. User 1 access program1. Program 1 can be accessed by many users at the same time due to business requirement. Hence, we can’t lock for user 1.
2. As we don’t want 2 users from same department to use this program same time due to business application limitation, we need to know whether any other user from same department is using this program when user 1 access.
Hope you have clear picture now. Any suggestions.