Key:ref: Difference between revisions

From OpenStreetMap Wiki
Jump to navigation Jump to search
Line 63: Line 63:


== Examples on relations ==
== Examples on relations ==
States use ref as the abbreviation of the state name. For example:
States and provinces are often tagged with a postal abbreviation in ref. For example:
* {{Tag|ref||CA}} The state of California (type=boundary, admin_level=4, name=California - currently relation 165475)
* {{tag|ref||CA}} The state of California (type=boundary, admin_level=4, name=California - currently relation 165475)


On road routes, the ref is a bare number, relying on {{tag|network}} to convey information about the road network:
Bus Routes use ref to label the bus route. For example:
* {{tag|network|US:I}} {{tag|ref||95}} Interstate 95 in the United States
* {{Tag|ref||23}} Bus route 23. (type=route, route=bus, name=Shanklin>Newchurch>Newport - currently relation 312207)

Bus routes use ref to label the bus route. For example:
* {{tag|ref||23}} Bus route 23. (type=route, route=bus, name=Shanklin>Newchurch>Newport - currently relation 312207)


== Examples on ways ==
== Examples on ways ==

Revision as of 03:54, 14 October 2014

Public-images-osm logo.svg ref
Description
Used for reference numbers or codes. Common for roads, highway exits, routes, etc. Edit this description in the wiki page. Edit this description in the data item.
Group: References
Used on these elements
may be used on nodesmay be used on waysmay be used on areas (and multipolygon relations)may be used on relations
Status: de facto

"ref" stands for "reference" and is used for reference numbers or codes. Common for roads, highway exits, routes, etc.

Key variations

There is a wide use of ref:*=*. Main values are listed above :

key used on description see taginfo (13 June 2013)
ref:INSEE=* admin_level=* INSEE code of the French communes Key:ref:INSEE 74,178
ref:isil=* library International Standard Identifier for Libraries Key:ref:isil 1,062
ref:lmi=* heritage id in Lista monumentelor istorice Proposed features/heritage 0
ref:mhs=* heritage id in the French database Mérimée of historic monuments Proposed features/heritage 4,764
ref:nid=* heritage id in Narodowy Instytut Dziedzictwa historic monuments Proposed features/heritage 1,533
ref:nrhp=* heritage identifiers for (United States) National Register of Historic Places (NRHP) records 22 NRHP advanced search 24
ref:rce=* heritage id in Rijksdienst voor het Cultureel Erfgoed Proposed features/heritage 8
ref:sandre=* river ref of the French Sandre agency WikiProject France/Cours d'eau 2,336
ref:svhl=* station-keys of Lübecker Stadtverkehr (Germany) Lübeck/Importe 2,289
ref:whc=* heritage id of the Unesco World Heritage Proposed features/heritage 226
ref:ERDF:gdo=* line or substation Id of French power distribution facilities Key:ref:ERDF:gdo 0
ref:FR:42C=* central_office Id of French telephone copper local loops facilities Key:ref:FR:42C 0
ref:bag=* Id of Dutch buildings BAGimport 0

Core values

None

User defined values

Any valid syntax value

Examples on relations

States and provinces are often tagged with a postal abbreviation in ref. For example:

  • ref=CA The state of California (type=boundary, admin_level=4, name=California - currently relation 165475)

On road routes, the ref is a bare number, relying on network=* to convey information about the road network:

Bus routes use ref to label the bus route. For example:

  • ref=23 Bus route 23. (type=route, route=bus, name=Shanklin>Newchurch>Newport - currently relation 312207)

Examples on ways

There are no global standards as to whether the refs include spaces, hyphens or other characters. At least when nationally consistent, tag what's on the ground. Some countries use spaces on the signs, others don't. In some countries the usage on the signs varies and guidelines are under discussion.

  • ref=A 1 Default reference (German and French references with a space; e.g., A 1)
  • int_ref=E 15 Internationally referenced as
  • nat_ref=A 1 Nationally referenced as (German and French references with a space; e.g., A 1)
  • reg_ref=A 1 Regionally referenced as (German and French references with a space; e.g., A 1)
  • ncn_ref=54 The number reference for a National Cycle Network. See Cycle_routes
  • ref=A 3;A 7 Default for more than one reference (German and French references with a space; e.g., A 1)

Examples on nodes

A ref on a node generally means a highway exit when combined with highway=motorway_junction:

  • ref=23 US Highway exits are often just a number
  • ref=23B Sometimes exits have been split into A and B exits.

ref is sometimes used on bus stops:

ref is sometimes used to label an entrance into a large parking area. For example a shopping mall may have entrances A - L:

Special uses

  • ref:svhl=* - station-keys of Lübecker Stadtverkehr (Germany) - details look at Lübeck/Importe
  • ref:luebeck=* - internal reference for objects the area of Lübeck
  • ref:bufa=* - 4-digit key of the local German tax and revenue offices (Bundesfinanzamtnummer)
  • ref:vatin=CC12345678 - VAT identification number of companies, use CountryCode (e.g. IT for Italy) and the number
  • official_ref=* - Used in cases where the official administrative reference for a road (or other feature) is not identical with the road signs (or other feature ref), e.g. because they are old, or because the administration doesn't have the money to change the signs.

See also

ref:FR:*=*
WikiProject France/Liste des références nationales

Notes

  • For highways shared by more than one route see Relations/Routes or Faq#What shall I do for roads that have multiple values for a tag?. Relations seem to be the preferred method for tagging this.
  • If more than one reference is given, you are recommended to separate them with a semicolon and without a space character, because this is the widely established syntax in Germany and maybe other countries. But note, this syntax is being heavily discussed in Germany. A better approach might be to have a namespace and add the entity that has issued the ref, e.g. ref:foo=x ref:bar=y.
  • Do not confuse this issue with the space that is present in some countries between the letter and the number in a reference itself.
  • When a road has no number, leave this key unused; this makes sure that routing programs do not try to describe the road by a number.