mysql MyISAM并发插入?
天蓬老师
天蓬老师 2017-04-17 13:52:01
0
2
803

mysql 数据库有一个表,tables_s,
本地客户端A连接此数据库后,
设置全局变量concurrent_insert =2,
并且对tables_s加并发共享读锁
lock table tables_s read local;
另外打开一个客户端B,按理说
执行insert into ......
操作时,应该能成功呀,怎么B客户端会进入等待状态,不执行插入语句?
求指教,可能我本身理解c错了。

天蓬老师
天蓬老师

欢迎选择我的课程,让我们一起见证您的进步~~

reply all(2)
Ty80

Myisam is a table-level lock, change it to innodb. Or other engines, innodb is transaction based and can roll back row-level locks.

Ty80

I don’t even understand the locking mechanism of mysiam, brother

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!