[转]排它锁&共享锁&乐观锁&悲观锁

1.排它锁 客户端1php set autocommit=0; BEGIN; SELECT * from bb_blog where id = 1 for update; update bb_blog set title = 5525 where id = 1; //这里没有提交事务 commit,由于提交以后就是解锁了 客户端1mysql SELECT * from bb_blog where
相关文章
相关标签/搜索