a guest Aug 18th, 2018 117 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- Insert and if it already exists update the columns SQL
- INSERT INTO users (firstname, lastname, email, mobile) VALUES ('Karem', 'Parem', 'email@example.com', '123456789');
- INSERT INTO users(firstname, lastname, email, mobile)
- VALUES ('Karem', 'Parem', 'firstname.lastname@example.org', '123456789')
- ON DUPLICATE KEY UPDATE
- firstname = 'Karem',
- lastname = 'Parem',
- email = 'email@example.com', -- you can probably omit this
- mobile = '123456789'
RAW Paste Data