UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'VIqJ5qnZ1TCuwZIXbhDe/eR6qhMsmzteGowtnMqpIjE='
WHERE
key_id = '70026aa0c3c23e3ccf590b9e857646d9735b104bd96671b42c2c332c2bc854ef'
AND (
token = 'VIqJ5qnZ1TCuwZIXbhDe/eR6qhMsmzteGowtnMqpIjE='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)