UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'CrUa7WXjGSsuNSFp4DYlbOGWRmdWeYB4/xjlizCzLCk='
WHERE
key_id = '4fc8c913492b3ec623f7fc2509be00c1c72ab9479ac15eeb28745bd4479d2923'
AND (
token = 'CrUa7WXjGSsuNSFp4DYlbOGWRmdWeYB4/xjlizCzLCk='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)