W3C home > Mailing lists > Public > public-rdf-dawg@w3.org > January to March 2010

Re: Property Paths Update (negated property classes)

From: Steve Harris <steve.harris@garlik.com>
Date: Tue, 16 Mar 2010 13:57:30 +0000
Cc: Lee Feigenbaum <lee@thefigtrees.net>, SPARQL Working Group <public-rdf-dawg@w3.org>
Message-Id: <8D9BD464-A9AB-4953-B255-9577C362D9F0@garlik.com>
To: Andy Seaborne <andy.seaborne@talis.com>
It's also possible (though far less convenient) to do SELECT DISTINCT ? 
p, then build that as a (x|y|...) set. For some data that set will be  
huge though.

- Steve

On 16 Mar 2010, at 10:16, Andy Seaborne wrote:

> This is Doug Reid's suggestion of:
>
> ?x !(rdf:type|^rdf:type) ?y
>
> or find all connections between ?x and ?y that are not via rdf:type,  
> in either direction.  This should extend to longer paths.
>
> ?x !(rdf:type|^rdf:type)* ?y
>
> # Added extra () for clarity of precedence.
> # ! binds tighter than * so it's not needed
> ?x (!(rdf:type|^rdf:type))* ?y
>
>
> The case of
>
> ?x !(rdf:type|rdfs:label) ?y
>
> without use of ^ works quite easily.  I am wondering about the need  
> for reversed properties
>
> A safe course of action would be to allow the case of forward  
> negated sets (^ can be applied outside the pattern).  It is quite  
> useful to match all but know unwanted properties.
>
> Some cases of "(^)" can be written in other forms (to get  
> semantically equivalent results - not exactly the same e.g. ?x/:a ? 
> y/:b and ?x/:b ?y/:a) but I haven't discovered whether this covers  
> all cases or not.
>
> 	Andy
>

-- 
Steve Harris, Garlik Limited
2 Sheen Road, Richmond, TW9 1AE, UK
+44 20 8973 2465  http://www.garlik.com/
Registered in England and Wales 535 7233 VAT # 849 0517 11
Registered office: Thames House, Portsmouth Road, Esher, Surrey, KT10  
9AD
Received on Tuesday, 16 March 2010 13:57:59 GMT

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