防止主键冲突报错-ignore

在mysql中如果插入重复的主键就会报错,为了防止报错,在主键重复插入的时候不进行插入,就要使用关键字 ignore



INSERT IGNORE INTO success_killed(seckill_id,user_phone)
VALUES (#{seckillId},#{userPhone})

https://blog.csdn.net/Winter_chen001/article/details/72875994



https://www.cnblogs.com/hanyouchun/p/6708037.html


Category storage