The following SPARQL query asks for the property names and values of all instances of the xyz:Employee class:

   PREFIX xyz: <http://example.org/sample#>
   PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>

   SELECT ?instance ?propertyName ?propertyValue
   WHERE
   {
      ?instance rdf:type xyz:Employee .
      ?instance ?propertyName ?propertyValue .
   }

It would probably be a good idea for you to work your way through a basic SPARQL tutorial. I can recommend one...

Bob DuCharme @bobdc
www.learningsparql.com @learningsparql



On 1/22/2013 5:58 AM, Soodeh Pakari wrote:

    Hi,

    I have an ontology that I want to access all individuals of the
    certain class and then access to all properties of these
    individuals. Is there any way to do this? Could you please help me?

    Thanks in advance

    Soodeh.



Reply via email to