UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'J0+0i8JRkzz54PJlvZs05HGZfvhKeqRmYBU/1oSrVmA=' 
WHERE 
  key_id = '628229475ec1c713800419a0cbf4385e1c4b9c2f8573b7e89713c96221abddc0' 
  AND (
    token = 'J0+0i8JRkzz54PJlvZs05HGZfvhKeqRmYBU/1oSrVmA=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00031