Get the App
SLTechnology News&Howtos  ›  Database  › 

How to see which painting of the lock is blocking which painting in the database

Shulou Source: shulou.com Published: 2022-05-31 15:19:32 10月02日 Update

This article mainly introduces how to check which painting of the lock blocks which painting in the database, which has a certain reference value, and interested friends can refer to it. I hope you will gain a lot after reading this article. Let's take a look at it.

See which painting is locked and which is blocked.

Select / * + no_merge (a) no_merge (b) * /

(select username from v$session where sid = a.sid) blocker

A.sid

'is blocking'

(select username from v$session where sid = b.sid) blockee

B.sid

From v$lock a, v$lock b

Where a.block = 1

And b.request > 0

And a.id1 = b.ID1

And a.id2 = b.id2

Thank you for reading this article carefully. I hope the article "how to check which painting in the database blocks which painting in the lock" shared by the editor will be helpful to everyone. At the same time, I also hope that you will support and pay attention to the industry information channel. More related knowledge is waiting for you to learn!

Tags: Painting articles blocking data database value interest at the same time more friends knowledge editing industry information information channels channels references learning help support Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Tech Info MySQL Shulou Information Shulou Technology NVidia