rdf - how to exclude one instance from SPARQL query result -
i have query similar instances specific instance, owbes:dies_irae instance. query:
construct { ?recommendable0 ?predicate0 ?similarity0 } {   ?recommendable0 ?predicate0 ?object0.   owbes:dies_irae ?predicate0 ?object0.   ?predicate0 owbes:hassimilarityvalue ?similarity0.   ?recommendable0 rdf:type ?sometype.   ?sometype rdfs:subclassof owbes:recommendable. } it works fine, in results i'm supposed to. however, same instance owbes:dies_irae. there way exclude result?
well, i'm sure there is. tried search, found there filter, tried use it, no succeed.  filter apply filter (?recmmendable0 != owbes:dies_irae)
i tried check if both of them have same rdf:about didn't work.
here go result:
<http://www.welovethesemanticweb.com/recommendation-systems#requiem:_sequentia>         recommendation-systems:hasartist                 "0.4"^^xsd:double .  recommendation-systems:le_nozze_di_figaro         recommendation-systems:hasartist                 "0.4"^^xsd:double .  recommendation-systems:dies_irae         recommendation-systems:hasartist                 "0.4"^^xsd:double . as see, last instance 1 i'd exclude
filter (?recmmendable0 != owbes:dies_irae) you didn't spell recommendable0 correctly in filter.  since variable isn't used anywhere else, never has value, filter doesn't have compare.
Comments
Post a Comment