UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'LWYN722oVR4t+MFJ6RfWuwzmOTBqtb0fbgYXNiECgMQ='
WHERE
key_id = 'e927f8ab852bb8acc5daa98585dbdd3826b3f21ba57e98190591616d4b6d39d2'
AND (
token = 'LWYN722oVR4t+MFJ6RfWuwzmOTBqtb0fbgYXNiECgMQ='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)