W3C home > Mailing lists > Public > public-rdf-dawg@w3.org > July to September 2005

Re: writing a triple filter?

From: Kendall Clark <kendall@monkeyfist.com>
Date: Fri, 5 Aug 2005 17:43:25 -0400
To: "Seaborne, Andy" <andy.seaborne@hp.com>
Cc: DAWG Mailing List <public-rdf-dawg@w3.org>
Message-ID: <20050805214325.GD13474@monkeyfist.com>

On Fri, Aug 05, 2005 at 10:31:28PM +0100, Seaborne, Andy wrote:

> Exactly how will depend on exactly what you are trying to eliminate but ....
> 
> CONSTRUCT { ?s ?p ?o }
> WHERE { ?s ?p ?o . FILTER ( ?s != <subj> && ?p != <pred> && ?o != "obj" ) }
> 
> does one simple case.

Hmm, so...

CONSTRUCT { <ground triples...> 
	    ?s ?p ?o }
WHERE     { ?s ?p ?o.
	    FILTER( ?s != <myfoaf:kendall> && 
	    	    ?p != <foaf:knows> && 
		    ?o != <myfoaf:edd> ) }

Yes, I believe that gives the results I wanted. I'll modify my CONSTRUCT
test case, and trust that someone who knows how will add it to the suite. Or
something.

Thanks, Andy.

Cheers, 
Kendall
Received on Friday, 5 August 2005 21:45:40 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 16:15:24 GMT