Wikidata:WikiProject WLM/Mapping tables/se

Step 1: What is implicity known about the data?

edit

Some Wikidata properties are self-evident by the object being in a particular list. Those can be identified and mapped directly. E.g. all the objects are from the country (P17) named Sweden (Q34)

Implicit data
field name value Wikidata property comment
country Sweden (Q34) country (P17)
wikiproject sv.wikipedia - used for getting Wikidata items from wikilinks

Step 2: analyze the WLM data and begin mapping

edit

Look at a few examples of the full data in the database behind the list on Commons. If you know how to get data out of a SQL-file, you can download a full dump of the Wiki Loves Monuments database [1]. Otherwise feel free to contact User:Mattias Östmar (WMSE) and I'll help you get the data out into a format that you can easily look through.

2.1 Data in the general table monuments_all

edit

Below is a list of all the fields in the monuments_all table with examples of what the values can look like for items located in Sweden. I've added an English translation of the field value in bold parantheses behind for your convenience.

heritage field example value Wikidata property Conversion comment
country se-bbr - For Sweden, this field can have 1 of 4 values: se-ship, se-fornmin, se-bbr, se-arbetsl. Determines which specific table to use.
lang sv - Language for item labels.
id 21300000013599 - Handled by more specific table (inferred from country).
project wikipedia -
adm0 se - handled by Implicit mappings
adm1 se-ab - not needed since we know municipality
adm2 Vaxholm located in the administrative territorial entity (P131) map free text municipality name to an item (differs from label by the ending "(s )kommun" and possible capitalization)

Might be better to map to English label ("$placename Municipality"), as not all Swedish names follow the "$placename+s kommun" pattern
The target item must have instance of (P31)municipality of Sweden (Q127448)
adm3 Storfors

[[Bergshamra, Norrtälje kommun|Bergshamra]]

location (P276) Get item from article Sometimes wikilinked, sometimes not -- only use if wikilinked.
adm4 null - For adm0="se", this is always NULL
name [[Bogesunds slott]] (Bogesund 1:82; f.d. Bogesund 1:1)

[[Saint Andrew's Church, Göteborg|Engelska kyrkan]]<br />([[Inom Vallgraven]] 30:2 f.d. Engelska kyrkan 2)

(Västra Frölunda 42:1, Hällristning)
label, P? Wikisyntax needs to be stripped String needs to be split where the bracketed text (fastighetsbeteckning) becomes the value of P? (to be identified). Note that the first part may be wikilinked and contain multiple parts.

If it's an se-fornmin item, then "name" should be handled by that specific table (as it splits the name of the item into the actual name and raä-number, and sometimes only the last one is present).

address [[Norsborg]], söder om [[Botkyrka kyrka]]

vid [[Ekholmens naturreservat]]

Anders Carlssons gata 1

[[Masthugget]] ([[Linnégatan, Göteborg|Linnégatan]] 1 och</br>Linnégatan 3)

? The values are a mixture of places and addresses (wiki linked and not).

For wikilinked adresses a combination of located on street (P669) and house number (P670) can be used, for plain text adresses use P969 (P969). But to do this, we need a way of distinguishing placenames from street addresses. If the field contains a number, it's an indicator it could be a street address, but then see the last example.

For non-addresses: We can use location (P276) if they are wikilinked, but nothing otherwise.

municipality Vaxholm - Handed by adm2
lat 59.39395 coordinate location (P625) lat + lon to Globe coordinate datatype. Combines the value of bot lat and lon.
lon 18.28676 see lat see lat
image Bogesunds Slott.JPG image (P18) string value
commonscat Bogesunds_slott Commons category (P373) string value
source //sv.wikipedia.org/w/index.php?title=Lista_%C3%B6ver_byggnadsminnen_i_Stockholms_l%C3%A4n&oldid=35302942 -
monument_article Bogesunds_slott see comment get item from link Gives the (likely) object for the monument
registrant_url http://www.bebyggelseregistret.raa.se/bbr2/anlaggning/visaHistorik.raa?page=historik&visaHistorik=true&anlaggningId=21300000013599 -
changed 2016-06-02 04:49:26 see comment if statements are sourced then this might be useful to store

2.2. Country-specific tables

edit

For Sweden, there are four country-specific tables, please see their separate pages: