UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = '68r2sKorZf39qyJ/Xll7NDnCti0vBLLIXolJWDdcZAY='
WHERE
key_id = '2708efef76c6d9d8a00eecf0a26cd549148ca2dbead23cb6962e5b5e7825de4f'
AND (
token = '68r2sKorZf39qyJ/Xll7NDnCti0vBLLIXolJWDdcZAY='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)