UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'VweXFXf4xDEdaM9f0qIt1v/BUI/SXGvzWWBlaNpwpwQ='
WHERE
key_id = '43ecdae985c7acc63bd4a2240aa668c9a44af25659b674cc39c7aebdd8c7fb46'
AND (
token = 'VweXFXf4xDEdaM9f0qIt1v/BUI/SXGvzWWBlaNpwpwQ='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)