title: SPARQL for DBPedia: Undefined namespace prefix at 'dbpedia-owl' before
body: <p>Trying to re-use <a href="http://dbpedia.org/sparql/?default-graph-uri=http://dbpedia.org&amp;query=select%20?a%20?b%20?super%20%28?aLength%20%2B%20?bLength%20as%20?length%29%0D%0A%7B%0D%0A%20%20values%20%28?a%20?b%29%20%7B%20%28dbpedia-owl%3APerson%20dbpedia-owl%3ASportsTeam%29%20%7D%0D%0A%20%20%0D%0A%20%20%7B%20select%20?a%20?super%20%28count%28?mid%29%20as%20?aLength%29%20%7B%20%0D%0A%20%20%20%20%20%20?a%20rdfs%3AsubClassOf%2A%20?mid%20.%0D%0A%20%20%20%20%20%20?mid%20rdfs%3AsubClassOf%2B%20?super%20.%0D%0A%20%20%20%20%7D%0D%0A%20%20%20%20group%20by%20?a%20?super%0D%0A%20%20%7D%0D%0A%20%20%7B%20select%20?b%20?super%20%28count%28?mid%29%20as%20?bLength%29%20%7B%20%0D%0A%20%20%20%20%20%20?b%20rdfs%3AsubClassOf%2A%20?mid%20.%0D%0A%20%20%20%20%20%20?mid%20rdfs%3AsubClassOf%2B%20?super%20.%0D%0A%20%20%20%20%7D%0D%0A%20%20%20%20group%20by%20?b%20?super%0D%0A%20%20%7D%0D%0A%7D%0D%0Aorder%20by%20?length%0D%0Alimit%201&amp;format=text/html&amp;timeout=30000&amp;debug=on" rel="nofollow noreferrer">this script</a> which used to work before, but it gives errors now: </p>
  
  <pre><code>Virtuoso 37000 Error SP030: SPARQL compiler, line 5: Undefined namespace prefix at 'dbpedia-owl' before 'dbpedia-owl:SportsTeam'
  </code></pre>
  
  <p>and the script itself: </p>
  
  <pre><code>select ?a ?b ?super (?aLength + ?bLength as ?length)
  {
    values (?a ?b) { (dbpedia-owl:Person dbpedia-owl:SportsTeam) }
  
    { select ?a ?super (count(?mid) as ?aLength) { 
        ?a rdfs:subClassOf* ?mid .
        ?mid rdfs:subClassOf+ ?super .
      }
      group by ?a ?super
    }
    { select ?b ?super (count(?mid) as ?bLength) { 
        ?b rdfs:subClassOf* ?mid .
        ?mid rdfs:subClassOf+ ?super .
      }
      group by ?b ?super
    }
  }
  order by ?length
  limit 1
  </code></pre>
  
  <p>Any ideas how to update it? </p>