E t1 (x INT UNIQUE); INSERT INTO t1 VALUES(1),(2); INSERT INTO t1 VALUES(2),(3); ERROR 1062 (23000): Duplicate entry '2' for key 'x' SELECT * FROM t1; +------+ | x | +------+ | 1 | | 2 | +------+ INSERT IGNORE INTO t1 VALUES(2),(3); Query OK, 1 row affected, 1 warning (0.04 sec) SHOW WARNINGS; +---------+------+---------------------------------+ | Level | Code | Message | +---------+------+---------------------------------+ | Warning | 1062 | Duplicate entry '2' for key 'x' | +---------+------+---------------------------------+ SELECT * FROM t1; +------+ | x | +------+ | 1 | | 2 | | 3 | +------+ Converting values: CREATE OR REPLACE TABLE t2(id INT, t VARCHAR(2) NOT NULL, n INT NOT NULL); INSERT INTO t2(id) VALUES (1),(2); ERROR 1364 (HY000): Field 't' doesn't have a default value INSERT IGNORE INTO t2(id) VALUES (1),(2); Query OK, 2 rows affected, 2 warnings (0.026 sec) Records: 2 Duplicates: 0 Warnings: 2 SHOW WARNINGS; +---------+------+----------------------------------------+ | Level | Code | Message | +---------+------+----------------------------------------+ | Warning | 1364 | Field 't' doesn't have a default value | | Warning | 1364 | Field 'n' doesn't have a default value | +---------+------+----------------------------------------+ SELECT * FROM t2; +------+---+---+ | id | t | n | +------+---+---+ | 1 | | 0 | | 2 | | 0 | +------+---+---+ See INSERT ON DUPLICATE KEY UPDATE for further examples using that syntax. URL: https://mariadb.com/kb/en/insert-ignore/https://mariadb.com/kb/en/insert-ignore/