[data-shapes] question on sh:values (#849)

VladimirAlexiev has just created a new issue for https://github.com/w3c/data-shapes:

== question on sh:values ==
GDB devs are starting to scope out SHACL 1.2 implementation, and @robert-david and I got a very basic question that we weren't 100% certain about.

Continuing the example https://www.w3.org/TR/shacl12-core/#value-nodes-property-shapes, can you confirm that the shape below:
- will compute `ex:employeeCount` (if missing)
- will produce a Violation if `ex:employeeCount` is asserted with the wrong value
- won't produce a Violation if `ex:employeeCount` is (redundantly) asserted with the right value
```ttl
ex:Company-employeeCount
 a sh:PropertyShape ;
 sh:name "employee count" ;
 sh:description "The number of employees, automatically computed" ;
    skos:scopeNote "You can also assert the number manually, if you are so inclined" ;
    sh:minCount 1 ; # redundant because it's guaranteed by the automatic computation
    sh:maxCount 1 ; # to catch a wrong manually asserted value
 sh:path ex:employeeCount ;
 sh:datatype xsd:integer ;
 sh:values [
  shnex:count [
   shnex:pathValues ex:employee ;
  ]
 ] .
```
- if I change to eg `sh:datatype xsd:int` then it will always produce a Violation because `shnex:count` always returns `^^xsd:integer`

Thanks a lot in advance!!

Please view or discuss this issue at https://github.com/w3c/data-shapes/issues/849 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Friday, 3 April 2026 13:10:15 UTC