Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

At least in MySQL you can use “ON DUPLICATE KEY” to either ignore such things or optionally execute an update statement to change something about the matching row.

There is also REPLACE INTO

Assuming you have a relevant unique key setup of course.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: