Login to manage your account

Please enter a valid email address.
Forgot Password?
Please enter a valid password.
OR

Don't have an account yet? Sign up

What happens when InnoDB detects a deadlock?

  1. A Both transactions hang until timeout
  2. B It rolls back the transaction that has done less work
  3. C It restarts the MySQL server
  4. D It commits both transactions
Answer

It rolls back the transaction that has done less work

InnoDB detects the lock cycle and rolls back the cheaper victim with error 1213. Applications must be written to retry the failed transaction.

All MySQL MCQs

Login to manage your account

Please enter a valid email address.
Forgot Password?
Please enter a valid password.
OR

Don't have an account yet? Sign up as