0

How to merge insert and update in mysql like merge into queries in oracle? as if i am going to insert a row in database and it is already exist then it will update the existing row.

Rohin
  • 1
  • 3
  • possible duplicate of [How do I update if exists, insert if not (AKA "upsert" or "merge") in MySQL?](http://stackoverflow.com/questions/1218905/how-do-i-update-if-exists-insert-if-not-aka-upsert-or-merge-in-mysql) – Philip Rieck Feb 27 '14 at 19:53

1 Answers1

0

You can use REPLACE. See the documentation: https://dev.mysql.com/doc/refman/5.7/en/replace.html. If you need help with a specific query, please edit it into your question.

Lauri Laanti
  • 948
  • 7
  • 11