Help:List of datatypes

Using different datatypes, properties can be used to describe very different kinds of values. A complete list of all ' datatypes provided by Semantic MediaWiki and ' provided by other semantic extensions is available from special page "Types". The available datatypes are:

Enumerations and allowed values
In addition to assigning a datatype to a property, you can also restrict the allowed values to a given set (like a whitelist for property inputs). This is done by using the to enumerate its permitted values. This works for every datatype.

Units
allows a unit after the numeric value to distinguish values (e.g. "30 miles" versus "42 km"). To support automatic conversion and multiple unit formats, one needs to declare each supported unit as described in the documentation on custom units. Property values are then automatically converted between different units, so that users are free to use their preferred unit in each article yet still query and compare with property values in other articles.

Handling in earlier versions
Up to, datatypes had individual wiki pages in their own namespace called "Type". This was abolished to reduce the number of extra namespaces. You may still find expressions like "Type:Number" in places in this wiki. Both writings are accepted for assigning a datatype to a property.

In very early versions of SMW up to, properties with datatype were known as relations and only those used double colons (::) as the separator between property name and link text. All other properties (numbers, text, etc.) were known as attributes and had to use colon equals (:=) as the separator.

See Upgrading from SMW 0.7 to SMW 1.0 for other changes in SMW 1.0; if you're still using the older version of SMW, see semweb:Help:Annotation (SMW0.7) for documentation of Annotations in version 0.7.