UPDATE contact.smsout SET id_send=1 WHERE id_send=2 AND D1 < date_sub(now(), INTERVAL 1 hour);