UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'o/MWFqzfYQYxNelzbR6w+KZSAiMYAEI2OlX6FiQkE88='
WHERE
key_id = '4f894c96f71c6e948c9dddff5324a7f41e0de85a8e11f67404a6280910e8c8c1'
AND (
token = 'o/MWFqzfYQYxNelzbR6w+KZSAiMYAEI2OlX6FiQkE88='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)