tags:

views:

13

answers:

1

I am using MySql database Can we get the information of last deadlock occur?

I mean does the information of deadlocks store in database?if yes Can we get them easily?

+1  A: 

If you use MySQL with innodb, this might be usefull:

http://dev.mysql.com/doc/refman/5.0/en/innodb-deadlocks.html

Use SHOW ENGINE INNODB STATUS to determine the cause of the latest deadlock

And if you use Myisam, there are no deadlocks:

http://dev.mysql.com/doc/refman/5.0/en/internal-locking.html

MySQL uses table-level locking for MyISAM, MEMORY and MERGE tables [...] Table locking in MySQL is deadlock-free for storage engines that use table-level locking. Deadlock avoidance is managed by always requesting all needed locks at once at the beginning of a query and always locking the tables in the same order.

JochenJung
I want only Time
SAHIL SINGLA