Help:Datatype "Geographic coordinate"

Jump to: navigation, search
Geographic coordinate
Holds coordinates describing geographic locations
Further Information
Provided by: Maps (Semantic Maps)
Added in version: 1.0
Removed in version: still in use
Datatype ID:
Table of Contents

The datatype geographic coordinate is used for geographic locations. Each value specifies a single point on the surface of Earth by giving latitude and longitude coordinates in decimal degrees, or in degrees, minutes and seconds.

Since SMW 1.5.0, this datatype is no longer part of SMW but is instead defined in the Maps (formerly Semantic Maps) extension, which also provides further features for visualising values of this type on interactive maps (OpenLayers format, Google Maps format, Yahoo! Maps format, Map format and KML format).

Declaration and Usage

A property of this type can be declared by writing [[has type::Geographic coordinate]] on the property page.

Values are specified by giving the values of latitude and longitude, separated by a comma or a semicolon. Various notations can be used for the parts of a coordinate. In particular, their values can be written as decimal numbers (as in "48.854325°") or using minutes and seconds (as in "48°51′15,57″"). The letters "N", "S", W" and "E" are available to denote the points of the compass North, South, West, and East, but it is also possible to use signed numbers (with negative coordinates for denoting West/South). If no letters are given, then the default order is to supply the latitude (North/South) before the longitude (East/West).

The acceptable symbols for minutes and seconds are:

  • The prime ′ and double prime ″ symbols (or their character entity references ′ and ″, or their decimal character references ′ and ″)
  • apostrophe ' and double-quote " on most computer keyboards
  • one acute accent symbol ´ and two acute accent symbols ´´ (or its character entity reference ´, or its decimal character reference ´).

You can optionally follow the latitude and longitude coordinates with the degree symbol ° (or its character entity reference ° or its decimal character reference °).

The net of these rules is that most coordinate formats, including GeoURL format and geotag format will be recognized. If not, you can use a semantic template.


Below are some examples of correct coordinates. As the symbols used for degrees, minutes, and seconds can be confused with a variety of other similar symbols, it can be helpful to copy directly from these examples.

[[Test geographic coordinate:: 32°42′54″ N, 117°9′45″ W]]
[[Test geographic coordinate:: 32.715° N, 117.163° W]]
[[Test geographic coordinate:: -32.715°, -77.03201°]]

Properties using Geographic coordinate can use service links to generate links to map services for coordinates; take a look at Property:Has coordinates and the factbox of pages using it such as Berlin.

Semantic search

Using coordinate properties for searching pages can be done in a similar fashion as for all other properties; see Help:Semantic search. As with any property, you can use the + wildcard to select all pages with some value for a geographic coordinate property, for example
{{#ask: [[Test geographic coordinate::+]] }}

Related query syntax elements


Help pageSyntax elementDescription
#ask: annotation query marker
Marks an inline query as part of an annotation1
#ask: control query marker
Allows to dynamically alter a result display without the need to reload a page2
#ask: deferred query marker
Marks an inline query as deferred from regular parsing2
#ask: hierarchy depth restriction
Restricts the hierarchy depth of a query3
#ask: printout column width
Defines a width for a printout column4
#ask: printout column width
Defines an alignment for the content of a printout column

This documentation page applies to all SMW versions from 1.0 to the most current version.
      Other languages: dezh-hans

Help:Type Geographic coordinate en 1.0


  1. ^  Semantic MediaWiki: GitHub pull request gh:smw:2572
  2. a b  Semantic MediaWiki: GitHub pull request gh:smw:2398 (Add support for @deferred mode)
  3. ^  Semantic MediaWiki: GitHub issue gh:smw:2662
  4. ^  Semantic MediaWiki: GitHub pull request gh:smw:2677