Встретил в коде следующий запрос:
INSERT INTO oauth_server_token
SET ost_osr_id_ref = %d,
ost_usa_id_ref = 1,
ost_token = '%s',
ost_token_secret = '%s',
ost_token_type = 'request',
ost_token_ttl = DATE_ADD(NOW(), INTERVAL %d SECOND)
ON DUPLICATE KEY UPDATE
ost_osr_id_ref = VALUES(ost_osr_id_ref),
ost_usa_id_ref = VALUES(ost_usa_id_ref),
ost_token = VALUES(ost_token),
ost_token_secret = VALUES(ost_token_secret),
ost_token_type = VALUES(ost_token_type),
ost_token_ttl = VALUES(ost_token_ttl),
ost_timestamp = NOW()
Совершенно не понимаю, нафига там данные вставляются два раза?