N-ary relations

From NYC Resistor Wiki
Jump to navigation Jump to search

An n-ary relation is a property that maps between a subject and two or more values. This is distinct from the most common type of property, a binary property which maps between a single subject and a single value. An n-ary relation cannot be split up into n binary properties, because the properties it defines are all interconnected in some way.

Implementation in SMW 1.0[edit]

In SMW 1.0, you can specify that a property takes multiple values by enumerating a list of types in its Property:Has type.

For example, on ontoworld.org ow:Property:Employment with an employer, job title, start date and end date is specified as [[has type:=Page; String; Date; Date]]. Then you can give this property up to four single values (again separated by ";"). You can use "" or "?" for omitted values.