Hi,

we encountered a strange deadlock problem with maxdb 7.5.0.30
Taking two tables A and B.
B references A by a foreign key on cascade delete (or cascade set null).

As far as I understood the following locking will happen internally if I remove a row from A:

  1. exclusive row lock on A
  2. shared table lock on B
  3. exclusive row lock on B
  4. delete row on A
  5. delete row on B

If I remove two different rows from A simultaneously there could be a deadlock if Step 2 if both processes will be executed at nearly the same time.
One process will be rolled back.
So far so good.
But if this happend with 3 or more processes only one process will be rolled back. The others will stay in deadlock situation and nothing happens there any more.

My questions:

  1. How can I avoid this deadlock situation in general?
  2. If this is not possible, how can I avoid the problem with 3 or
     more processes.

regards,

Michael





--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to