UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = '/3Lp4MNjfp2mg0rsfGzIBJwqA4SPjDmL8x35LJc/RNE='
WHERE
key_id = 'eb19ed5ab17cf37e46f3849f9fdb709ea127d0a04e11347d03929c0f94b98e41'
AND (
token = '/3Lp4MNjfp2mg0rsfGzIBJwqA4SPjDmL8x35LJc/RNE='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)