About the database locking

http://en.wikipedia.org/wiki/Lock_%28database%29

 

Locking not only provides exclusivity to writes but also prevents (or controls) reading of unfinished modifications (AKA uncommitted data).

 

i think the exclusivity to writes only includes other writes but reads.

if not, there's no need to say the next part "but also prevents (or controls) reading of unfinished modifications (AKA uncommitted data)."

cause if reading is not permitted amongst writing, no reading of unfinished modifications will occur.

 

 

锁不仅提供了对写操作排他性 ,(就是在一个线程对数据进行写操作的时候,不允许其他线程同时对同一数据进行写操作),也阻止或控制了对未完成修改的数据的读操作 ,也叫作未提交数据。也就是写前可读,写中不可读,写完可读;读前可写,读中不可写(我不清楚有没有读中概念,如果读是一个原子操作的话,就没有读中概念,也不存在读中不可写的问题),读完可写。

and please browse the detailed operations:
http://www.cnblogs.com/lingmaozhijia/articles/1339222.html

你可能感兴趣的:(html)