mysql中 insert ignore 的使用示例如下:

  INSERT IGNORE INTO `table_name` (`reportid`, `content`) VALUES (‘11111’,‘hello’);

  需要注意的是,如果对应的表没有加唯一索引或者相应主键的话,insert ignore是不起作用的。

相关文章:

  • 2022-12-23
  • 2021-05-11
  • 2021-12-12
  • 2022-12-23
  • 2022-12-23
  • 2021-06-12
  • 2021-06-02
  • 2021-12-24
猜你喜欢
  • 2021-11-02
  • 2022-12-23
  • 2022-12-23
  • 2021-07-30
  • 2022-12-23
  • 2021-11-06
相关资源
相似解决方案