UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'xaoF+puOwJWvR4P6IrP7J9zjc+tvd43+cJ02Od4cnro='
WHERE
key_id = '92c044ec1ed116a6c3f47d7a1984de0c3986308e2a82fb7257db7ed3b58b54b8'
AND (
token = 'xaoF+puOwJWvR4P6IrP7J9zjc+tvd43+cJ02Od4cnro='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)