ééã£ã¦ä¸»ãã¼ã¨åãå¤ãå«ãè¡ãæ¿å ¥ãããã¨ãããã¨ã©ã¼ãåºãã¦æãã¦ã»ããã¨ã INSERT INTO test VALUES(1,100); ã¨ããã¨ãERROR 1062 (23000): Duplicate entry '1' for key 1 ã¨ããã¨ã©ã¼ãåºãã ééã£ã¦ä¸»ãã¼ã¨åãå¤ãå«ãè¡ãæ¿å ¥ãããã¨ãã¦ãç¡è¦ãã¦å¦çãç¶è¡ãã¦ã»ããã¨ã INSERT IGNORE INTO test VALUES(1,100); ã¨ããã¨ãQuery OK, 0 rows affected (0.00 sec) ã¨è¡¨ç¤ºãããããã¼ãã«ã¯å¤æ´ããã¦ããªãã 主ãã¼ã¨åãå¤ãå«ãè¡ããªããªãæ°ããæ¿å ¥ãããããªããã®è¡ãæ´æ°ãã¦ã»ããã¨ã REPLACE INTO test VALUES(1,500); ã¨ããã¨ãQuery OK, 2 rows affected (0.00 sec)
{{#tags}}- {{label}}
{{/tags}}