https://social.msdn.microsoft.com/Forums/sqlserver/en-US/dba45618-1d64-4661-891d-74cab09dddf1/deadlock-while-running-multiple-update-statements?forum=sqldatabaseengine

Update statement on your table introduces table scan. It means, that SQL Server reads every row in your table to check if row needs to be updated. During that read operation SQL Server  issues (U) update lock on the row. In case if row needs to be updated, it converts (U) lock to (X) exclusive lock and held that lock till end of transaction. (U) locks are incompatible with other (U) nor (X) locks.

In your case you have 2 sessions waiting for each other. Each session puts X lock on (different) rows and tries to issue (U) lock and read the row updated by other session (with (X) lock held). It's a bit more complicated actually - you have more than 2 sessions involved but I hope you get an idea.

Create an index on iPHMD_InterestList_ID to avoid table scans during update

multi update caused deadlock problem的更多相关文章

  1. [转]两表join的multi update语句在MySQL中的执行流程分析

    出自:http://hedengcheng.com/?p=209 两表join的multi update语句,执行结果与预计不一致的分析过程 — multi update结论在实际应用中,不要轻易使用 ...

  2. sql server deadlock problem

    https://www.red-gate.com/simple-talk/sql/learn-sql-server/how-to-track-down-deadlocks-using-sql-serv ...

  3. 【转】表删除时 Cannot delete or update a parent row: a foreign key constraint fails 异常处理

    转载地址:http://lijiejava.iteye.com/blog/790478 有两张表,结构如下: t_item:                          t_bid: id    ...

  4. 表删除时 Cannot delete or update a parent row: a foreign key constraint fails 异常处理

    有两张表,结构如下: t_item:                          t_bid: id        int                     id        int n ...

  5. Understanding the Uncertain Geographic Context Problem

    "The areal units (zonal objects) used in many geographical studies are arbitrary, modifiable, a ...

  6. mongodb3.2系统性学习——3、update()操作

     mongodb 包含众多的原子性操作: 实例: //连接数据库 dbService = connect("localhost:27017"); //选择插入集合 db = dbS ...

  7. java 并发官方教程

    http://docs.oracle.com/javase/tutorial/essential/concurrency/index.html Concurrency Computer users t ...

  8. Known BREAKING CHANGES from NH3.3.3.GA to 4.0.0

    Build 4.0.0.Alpha1 =============================   ** Known BREAKING CHANGES from NH3.3.3.GA to 4.0. ...

  9. DB2 Error Messages (Sorted by SQLCODE)

    DB2 Error Messages (Sorted by SQLCODE) DB2 Error Messages (Sorted by SQLCODE) SQLCODE SQLSTATE Descr ...

随机推荐

  1. linux安装consul集群

    一.集群规划 consul借助agent来运行,类似elk的logstash agent 或 zabbix监控系统的agent , 每个需要被发现的服务上,通过consul agent client ...

  2. http://www.haolizi.net/example/view_2380.html

    null

  3. FZU2030(括号匹配)

    题目链接:http://acm.hust.edu.cn/vjudge/contest/view.action?cid=110977#problem/E 题目大意:略 题目思路:数据范围很小,可以搜索, ...

  4. HDU3037 附Lucas简单整理

    Saving Beans Time Limit: 6000/3000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Tota ...

  5. 【BZOJ2882】工艺 后缀自动机

    [BZOJ2882]工艺 Description 小敏和小燕是一对好朋友. 他们正在玩一种神奇的游戏,叫Minecraft. 他们现在要做一个由方块构成的长条工艺品.但是方块现在是乱的,而且由于机器的 ...

  6. Sping Cloud 微服务框架学习

    Spring Cloud官方中文站 https://springcloud.cc

  7. Hystrix 基于注解开发

    不对地方,请指出!相互学习! 背景:Hystrix 没有无参构造函数,所以Spring管理bean时候没办法进行管理, 每个类都进行编码 个人感觉不方便,基于注解开发!方便速度快,不侵入代码!引入的j ...

  8. mock数据(模拟后台数据)

    mock数据(模拟后台数据) - Emily恩 - 博客园 https://www.cnblogs.com/enboke/p/vue.html Mock.js http://mockjs.com/ 前 ...

  9. Linux考试题附答案

    一.选择题 1.在登录Linux时,一个具有唯一进程ID号的shell将被调用,这个ID是什么(B)? A.NID B.PID C.UID D.CID 2.下面哪个目录存放用户密码信息(B) A./b ...

  10. CSS3 animation-iteration-count:infinite

    原文:http://www.w3chtml.com/css3/properties/animation/animation-iteration-count.html animation-iterati ...