UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'pUpBlqo+DYNZXwt+A799hIlRn4RMOfifJ6+KTaZfTUs='
WHERE
key_id = '72395bd07464e7b041d89aea60fb7ae1a7f2870a59ab0b2717400e2b0398c1e9'
AND (
token = 'pUpBlqo+DYNZXwt+A799hIlRn4RMOfifJ6+KTaZfTUs='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)