sparqldbpediafoaf

SPARQL DbPedia foaf:name


Trying to execute some queries but when searching for foaf:name resultset is empty. Here's my code:

SELECT DISTINCT ?uri ?string 
WHERE {
    ?uri rdf:type ?x.       
        ?uri foaf:name 'Cavallo domestico'@it   .
        OPTIONAL { ?uri rdfs:label ?string . FILTER (lang(?string) = 'it') }
}

page exist http://it.dbpedia.org/resource/Equus_caballus/html

Apparently seems it's not related with languages different than english but with foaf:name request. If I execute following, retrieving generic foaf:givenName, it works:

SELECT DISTINCT ?uri ?string 
WHERE {
    ?uri rdf:type ?x.       
        ?uri foaf:givenName 'Jimmy'@en   .
        OPTIONAL { ?uri rdfs:label ?string . FILTER (lang(?string) = 'en') }
}

Solution

  • I think this wasn't working when I first mentioned that it didn't in a comment, but, as AKSW points out, this seems to be working now. The rdfs:label property has the article titles in various languages, not the foaf:name, so you can do this to get the types of Horse:

    select ?x ?type {
      ?x a ?type ;
         rdfs:label "Equus caballus"@it
    }
    

    SPARQL results