Search code examples
sparqldbpedia

Get properties of a given DBpedia category


I'm trying to get skos:broader of a given DBpedia category, but it gives me a null result.

This is my SPARQL request:

  select ?value where { 
     <http://dbpedia.org/page/Category:Watches> skos:broader ?value 
      }

Solution

  • The URI for DBpedia resources is http://dbpedia.org/resource/<title>, it's not http://dbpedia.org/page/<title>, that's the URL of the DBpedia page describing the resource.

    So, your query should be:

    select ?value where { 
      <http://dbpedia.org/resource/Category:Watches> skos:broader ?value 
    }
    

    Or shorter:

    select ?value where { 
      dbc:Watches skos:broader ?value 
    }