UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = '/kho0b5Usy/K14DHxaPCutYL3gljrmAr9S21V+q31o4='
WHERE
key_id = 'e62afe5dc3fa711e3a2d584abe1bb948324d2ea00f336bfb6f3bc3dd086c7d38'
AND (
token = '/kho0b5Usy/K14DHxaPCutYL3gljrmAr9S21V+q31o4='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)