- From: Holger Knublauch <holger@topquadrant.com>
- Date: Fri, 25 Sep 2015 09:12:23 +1000
- To: public-data-shapes-wg@w3.org
Received on Thursday, 24 September 2015 23:13:00 UTC
On 9/25/2015 2:55, Solbrig, Harold R. wrote: > Folks, > > I'm looking over the property constraints and trying to understand the > behavior if (a) there are not triples in the graph whose subject is > the supplied focus node or (b) there are no triples in the graph with > the propertyConstraint predicate. I am not an expert in SPARQL, but > it would appear that: > SELECT $this ($this AS ?subject) $predicate (?value AS ?object) > WHERE { > $this $predicate ?value . > FILTER NOT EXISTS { > GRAPH $shapesGraph { > $allowedValues (rdf:rest*)/rdf:first ?value . > } > } > } > Would pass (not return any triples) in either case. Is this true, or > am I just misreading the SPARQL? If it is true, is this what is intended? Yes your interpretation is correct and as intended. To enforce the presence of at least one value, sh:allowedValues needs to be combined with sh:minCount>0 Holger
Received on Thursday, 24 September 2015 23:13:00 UTC