What is deadlock and how to avoid the deadlocks.
Answer Posted / dba
P1 has lock on R1
P2 has lock on R2
P1 requests lock on R2
P2 Requests lock on R1
Where P & R are corresponding processes and resources.
Deadlock consists of two processes requesting locks on
resources thus, blocking each other.
You can avoid Deadlocks:
Access objects in the same order
Use lower isolation levels
Keep Transactions short and in one batch
Avoid user interactions in transaction
Use bound connections
Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
Can you pass expressions to stored procedure parameters?
how can a database be repaired? : Sql server administration
Explain in brief about Microsoft SQL server?
What is sql server transaction log file?
What is precedence constraint?
What are the various Operating system files that every SQL server 2005 database has and what is the purpose.
How do you know if sql server is running on your local system?
What are the differences between “row_number()”, “rank()” and “dense_rank()”?
What is the difference between nvl and nvl2?
How to delete a login name in ms sql server?
Can we insert data into view sql server?
How to drop existing indexes in ms sql server?
How do you rename a table in sql server?
Explain sub-query?
What do you mean by tablesample?