UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'VOouYLuxJuwOhMCxbQm4OPcFiU//O26EMZUhN7GVOM0=' 
WHERE 
  key_id = 'b1ddf69ec2aefbfe57e522bf459ee7ea943b747a8a3e75a14ad94756a83fcfdf' 
  AND (
    token = 'VOouYLuxJuwOhMCxbQm4OPcFiU//O26EMZUhN7GVOM0=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00017