fibo2023Q3 / src /etc /testing /hygiene_parameterized /testHygiene_properties_punning_chain.sparql
wikipunk's picture
add FIBO Q3 2023 release to src
38b6321
raw
history blame
600 Bytes
prefix owl: <http://www.w3.org/2002/07/owl#>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
##
# banner We should avoid punning object and datatype properties
SELECT DISTINCT ?error ?property
WHERE
{
?resource owl:propertyChainAxiom ?axiom.
?axiom rdf:rest*/rdf:first ?property .
?property rdfs:subPropertyOf*/rdf:type owl:DatatypeProperty.
FILTER regex(str(?property), <HYGIENE_TESTS_FILTER_PARAMETER>)
BIND (concat ("WARN: Datatype property ", str(?property), " occurs in a property chain") AS ?error)
}