Re: Dumb SPARQL query problem

Its’ the other bit of the pig’s breakfast.
Try an @en

On 23 Nov 2013, at 10:18, Richard Light <richard@light.demon.co.uk> wrote:

> Hi,
> 
> Sorry to bother the list, but I'm stumped by what should be a simple SPARQL query.  When applied to the dbpedia end-point [1], this search:
> 
> PREFIX foaf: <http://xmlns.com/foaf/0.1/>
> PREFIX dbpedia-owl: <http://dbpedia.org/ontology/>
> SELECT *
> WHERE {
>     ?pers a foaf:Person .
>     ?pers foaf:surname "Malik" .
>     OPTIONAL {?pers dbpedia-owl:birthDate ?dob }
>     OPTIONAL {?pers dbpedia-owl:deathDate ?dod }
>     OPTIONAL {?pers dbpedia-owl:placeOfBirth ?pob } 
>     OPTIONAL {?pers dbpedia-owl:placeOfDeath ?pod } 
> }
> LIMIT 100
> 
> yields no results. Yet if you drop the '?pers foaf:surname "Malik" .' clause, you get a result set which includes a Malik with the desired surname property.  I'm clearly being dumb, but in what way? :-) 
> 
> (I've tried adding ^^xsd:string to the literal, but no joy.)
> 
> Thanks,
> 
> Richard
> [1] http://dbpedia.org/sparql
> -- 
> Richard Light

-- 
Hugh Glaser
   20 Portchester Rise
   Eastleigh
   SO50 4QS
Mobile: +44 75 9533 4155, Home: +44 23 8061 5652

Received on Saturday, 23 November 2013 10:30:44 UTC