This view shows the status of locks on database objects that are held or being requested by Adaptive Server processes, as of the end of the most recent sample interval. Each lock is identified by the name and ID of the object being locked, the name and ID of the database that contains that object, and the page number to which the lock applies (if it is a page lock).
Each Adaptive Server process associated with the lock is also identified by its login name, Process ID, and Kernel Process ID. The type of lock is presented, together with the current status of the lock and an indication of whether or not this is a demand lock. If the lock is being requested by the process, the amount of time that this process waited to acquire the lock and the Process ID of the process that already holds the lock are shown. If, instead, the process already holds the lock, the count of other processes waiting to acquire that lock is shown.
hs_create_view object_lock_status, "Database ID", "Value for Sample", "Database Name", "Value for Sample", "Object ID", "Value for Sample", "Object Name", "Value for Sample", "Page Number", "Value for Sample", "Login Name", "Value for Sample", "Process ID", "Value for Sample", "Kernel Process ID", "Value for Sample", "Lock Type", "Value for Sample", "Lock Status", "Value for Sample", "Demand Lock", "Value for Sample", "Time Waited on Lock","Value for Sample", "Blocking Process ID", "Value for Sample", "Locks Being Blocked Count", "Value for Sample"