Oracle automatically detects deadlock situations and resolves them by rolling back one
of the statements involved in the deadlock, thereby releasing one set of the conflicting
row locks. A corresponding message also is returned to the transaction that undergoes
statement-level rollback. The statement rolled back is the one belonging to the
transaction that detects the deadlock. Usually, the signalled transaction should be
rolled back explicitly, but it can retry the rolled-back statement after waiting.
Note: In distributed transactions, local deadlocks are detected
by analyzing wait data, and global deadlocks are detected by a time
out. Once detected, nondistributed and distributed deadlocks are
handled by the database and application in the same way.
Deadlocks most often occur when transactions explicitly override the default locking
of Oracle. Because Oracle itself does no lock escalation and does not use read locks for
queries, but does use row-level locking (rather than page-level locking), deadlocks
occur infrequently in Oracle.
2. 当事务显示的覆盖了默认的锁方式时,更容易发生死锁 . 因为Oracle不会进行锁升级,
不会在查询时使用读锁 , 而使用行级别锁,这样发生死锁的现象就少见
来自 “ ITPUB博客 ” ，链接：http://blog.itpub.net/10599713/viewspace-990926/，如需转载，请注明出处，否则将追究法律责任。