UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'ArfFYJYmVJqO4z5QCQI6Sba7kO+gJvGNKboVgeAlfAE='
WHERE
key_id = '2238c4576419ebb7ea14c16546735ae267b61642f0b79cf08daf61b5414b0d00'
AND (
token = 'ArfFYJYmVJqO4z5QCQI6Sba7kO+gJvGNKboVgeAlfAE='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)