I have a sql query
INSERT INTO names ('name','mobile','timestamp') VALUES ('my name','123456','2016-10-08 17:59:54')
ON DUPLICATE KEY UPDATE:
INSERT INTO names (name, mobile, timestamp) VALUES ('my name', '123456', '2016-10-08 17:59:54') ON DUPLICATE KEY UPDATE name = VALUES(name), timestamp = VALUES(timestamp);
I assume the single quotes around the column names in the query in the question are just typos.