Negated Property Path
Opened this issue · 3 comments
I propose to add to SPARQL property path support for the equivalent of SPARQL's NegatedPropertySet
(re https://www.w3.org/TR/sparql11-query/#pp-language)
For example, !(ex:foo | ex:bar)
could be expressed as
[
sh:path [ sh:negatedPath [ sh:alternativePath ( ex:foo ex:bar ) ] ] ;
] .
The object of sh:negatedPath
would have to be defined as any valid SHACL Property Path
From the Jena implementation, it seems that the NegativePropertySet takes a list of either forward or backward properties as input, not any arbitrary path. So the exact syntax would need to be specified in a way that excludes the other cases (like oneOrMorePaths etc)?
Note that right now there is no SHACL 1.1 draft where this could be merged into though. Therefore a PR is difficult. We would need to get some dedicated individuals from other vendors to indicate whether a SHACL 1.1 effort (as a living standard) should be started.
From the Jena implementation, it seems that the NegativePropertySet takes a list of either forward or backward properties
Yes - that's how it is defined in SPARQL.
https://www.w3.org/TR/sparql11-query/#rPathNegatedPropertySet
NPS's aren't a general "any route except such-and-such"; they are a restriction on a single step in the path.
[@HolgerKnublauch] We would need to get some dedicated individuals from other vendors to indicate whether a SHACL 1.1 effort (as a living standard) should be started.
It might be worth starting a fresh issue, there to keep a living list (in its initial comment) of open issues (such as #19 and #20) that might together justify spinning up such a SHACL-1.1
(or SHACL-Next
) WG...