UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'Cluq84vCEnth53XZdYsrTuMFX9rTlRhG6+kVdiJfPwI='
WHERE
key_id = '52cd35c926dd63d0e48f41581cbb11fbbdd9685a0b76fd22b717b07b7dfaadb0'
AND (
token = 'Cluq84vCEnth53XZdYsrTuMFX9rTlRhG6+kVdiJfPwI='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)