Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Positions in Organizations

Count the types of positions in each organization

Positions relate a person to an organization.  Each position has a type – faculty, staff, etc.  We would like to know how many positions of each type are in each organization.  The query below is a start.  We could embellish the query with additional selection having to do with date ranges, positions per person, and so on.

Code Block
titleCount the types of positions in each organization
linenumberstrue


Individual Persons 

Retrieve the positions for a single person

The query begins by finding the person of interest – here the person is identified by the value of a label.  This may not return a single person.  But for this example, let's assume it does.  We could construct a query which selected the person based on their primary email or their ORCiD, or some other identifier.  The query then gets all the relatedBy assertions for this person.  VIVO uses relatedBy in many settings.  The query then limits the results to insure that the relatedBy assertions relate a foaf:Person to a vivo:Position.  The query then gets the labels for each position.

Note:  The use of SELECT * returns all variables used in the query.  

Code Block
titleRetrieve the positions for a single person
linenumberstrue
SELECT *
WHERE {
    ?person rdfs:label  'Conlon, Michael' .
    ?person vivo:relatedBy ?position .
    ?person a foaf:Person .
    ?position a vivo:Position .
    ?position rdfs:label ?position_label .
}