Deadlock troubleshooting in Sql Server 2008

后端 未结 3 610
北海茫月
北海茫月 2020-12-05 19:37

My website doesn\'t seem to handle a high number of visitors, I believe it\'s because the server is too simple.

2 hours ago my website was getting a lot of hits and

3条回答
  •  离开以前
    2020-12-05 20:05

    If you don't mind dirty reads you can try putting (NOLOCK) after your table names in your SELECT queries. The trade off here is that you are not guaranteed the most up to date data as UPDATE and INSERT statements currently executing are ignored.

    Usually this is not to much of a train-smash as most systems read far more than they update/insert, but obviously it depends on the nature of your application.

    Alternatively have a look at http://www.sql-server-performance.com/tips/deadlocks_p1.aspx

提交回复
热议问题