infered subject for a certain property value

Posted by gp on
URL: http://owlready.306.s1.nabble.com/infered-subject-for-a-certain-property-value-tp925.html

Hello!

I find the new INDIRECT_ prefix to obtain indirect relations very useful and exciting.
From the documentation I understand I cannot perform the inverse where I would query for all subjects which satisfy a certain property value. That is to say, the INDIRECT_ prefix allows me to perform something of the like of the following SPARQL query:

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> 
PREFIX obo: <http://purl.obolibrary.org/obo/> 
PREFIX cl: <http://purl.obolibrary.org/obo/cl.owl>

SELECT distinct ?cellPropValue

WHERE {
graph cl:
    {
       values ?cell {obo:CL_0000928}
       ?cell rdfs:subClassOf* ?cellAncestor .
        
       ?cellAncestor (rdfs:subClassOf|(owl:equivalentClass/owl:intersectionOf/rdf:rest*/rdf:first)) ?x .
       ?x owl:onProperty obo:RO_0002104 ;
          owl:someValuesFrom ?cellPropValue .
      }
}

Limit 100

But I cannot query for something like:

SELECT distinct ?cell ?cellPropValue

WHERE {
    graph cl:
    {   
#        values ?cell {obo:CL_0000928}
       values ?cellPropValue {obo:PR_000001874}
       ?cell (rdfs:subClassOf/(rdfs:subClassOf|(owl:equivalentClass/owl:intersectionOf/rdf:rest*/rdf:first))) ?x .
       ?x owl:onProperty obo:RO_0002104 ;
          owl:someValuesFrom ?cellPropValue .        

    }
}

Limit 100
where these queries are performed against the cell ontology.

Or did I miss something?

Cheers!
GP