Oracle数据库数据恢复、性能优化

找回密码
注册
搜索
热搜: 活动 交友 discuz
发新帖

316

积分

0

好友

0

主题
1#
发表于 2012-3-6 14:43:39 | 查看: 5982| 回复: 6
Share Row Exclusive Table Locks (SRX)A share row exclusive table lock (also sometimes called a share-subexclusive table lock, SSX) is more restrictive than a share table lock. A share row exclusive table lock is acquired for a table as follows:
LOCK TABLE table IN SHARE ROW EXCLUSIVE MODE; Permitted Operations: Only one transaction at a time can acquire a share row exclusive table lock on a given table. A share row exclusive table lock held by a transaction allows other transactions to query or lock specific rows using SELECT with the FOR
UPDATE clause, but not to update the table.
Prohibited Operations: A share row exclusive table lock held by a transaction prevents other transactions from obtaining row exclusive table locks and modifying the same table. A share row exclusive table lock also prohibits other transactions from obtaining share, share row exclusive, and exclusive table locks, which prevents other transactions from executing the following statements:
LOCK TABLE table IN SHARE MODE; LOCK TABLE table IN SHARE ROW EXCLUSIVE MODE; LOCK TABLE table IN ROW EXCLUSIVE MODE; LOCK TABLE table IN EXCLUSIVE MODE;


能否给个例子?
2#
发表于 2012-3-6 16:12:50
这个看的是 什么版本的文档?


SHARE ROW EXCLUSIVE MODE;   SSX/SRX


SELECT with the FOR UPDATE clause:

Until 9.2.0.5/6 "select for update"    =>  Sub-share (SS)  Row-share (RS)
"select for update" from 9.2.0.5/6     =>  Sub-exclusive(SX)   Row-exclusive(RX)


SSX, SRX is compatible with  SS,RS

回复 只看该作者 道具 举报

3#
发表于 2012-3-6 16:14:15

回复 只看该作者 道具 举报

4#
发表于 2012-3-6 16:17:58
11.2
http://docs.oracle.com/cd/E14072_01/server.112/e10592/ap_locks001.htm

A share row exclusive table lock (SRX), also called a share-subexclusive table lock (SSX), is more restrictive than a share table lock. Only one transaction at a time can acquire an SSX lock on a given table. An SSX lock held by a transaction allows other transactions to query or lock specific rows using SELECT ... FOR UPDATE, but not to update the table.

官方文档也有错啊。

回复 只看该作者 道具 举报

5#
发表于 2012-3-6 16:19:22
哦,原来如此,怪不得我自己没试出来啊。。。。。

回复 只看该作者 道具 举报

6#
发表于 2012-3-6 16:25:39

回复 只看该作者 道具 举报

7#
发表于 2012-3-6 16:45:02
11G 的 Concepts 靠谱一点。。。。

Share Row Exclusive Table Lock (SRX)

This lock, also called a share-subexclusive table lock (SSX), is more restrictive than a share table lock. Only one transaction at a time can acquire an SSX lock on a given table. An SSX lock held by a transaction allows other transactions to query the table (except for SELECT ... FOR UPDATE) but not to update the table.

回复 只看该作者 道具 举报

您需要登录后才可以回帖 登录 | 注册

QQ|手机版|Archiver|Oracle数据库数据恢复、性能优化

GMT+8, 2024-12-24 00:08 , Processed in 0.046982 second(s), 22 queries .

Powered by Discuz! X2.5

© 2001-2012 Comsenz Inc.

回顶部
TEL/電話+86 13764045638
Email service@parnassusdata.com
QQ 47079569