{"action":"opened","issue":{"url":"https://api.github.com/repos/catfan/Medoo/issues/318","labels_url":"https://api.github.com/repos/catfan/Medoo/issues/318/labels{/name}","comments_url":"https://api.github.com/repos/catfan/Medoo/issues/318/comments","events_url":"https://api.github.com/repos/catfan/Medoo/issues/318/events","html_url":"https://github.com/catfan/Medoo/issues/318","id":117154846,"number":318,"title":"REPLACE INTO feature missing in Medoo.","user":{"login":"jezmck","id":89996,"avatar_url":"https://avatars.githubusercontent.com/u/89996?v=3","gravatar_id":"","url":"https://api.github.com/users/jezmck","html_url":"https://github.com/jezmck","followers_url":"https://api.github.com/users/jezmck/followers","following_url":"https://api.github.com/users/jezmck/following{/other_user}","gists_url":"https://api.github.com/users/jezmck/gists{/gist_id}","starred_url":"https://api.github.com/users/jezmck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jezmck/subscriptions","organizations_url":"https://api.github.com/users/jezmck/orgs","repos_url":"https://api.github.com/users/jezmck/repos","events_url":"https://api.github.com/users/jezmck/events{/privacy}","received_events_url":"https://api.github.com/users/jezmck/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-11-16T15:54:40Z","updated_at":"2015-11-16T15:54:40Z","closed_at":null,"body":"Note that I am **not** referring to Medoo's [existing `replace` feature](http://medoo.in/api/replace).\r\n\r\nMySQL allows `REPLACE INTO` queries which update existing rows or insert new row into the database if matching ones don't exist.\r\n\r\n> REPLACE works exactly like INSERT, except that if an old row in the table has the same value as a new row for a PRIMARY KEY or a UNIQUE index, the old row is deleted before the new row is inserted.\r\nhttps://dev.mysql.com/doc/refman/5.7/en/replace.html\r\n\r\nThis is a massively useful feature which could be implemented for non-`MySQL` DBs if required.\r\n\r\nNote that I am **not** referring to Medoo's [existing `replace` feature](http://medoo.in/api/replace)."}}