Wikidata


Wolfgang Fahl

The Genesis of WikiData[edit]

The Genesis of WikiData

Entity:Queen Victoria[edit]

Statements
PropertyId/name value
P18/image 250px-Queen_Victoria_by_Bassano.jpg
P569/date of birth 24 May 1819
P39/position held Q9134365/Monarch of the United Kingdom qualifiers -> start:20 June 1837, end:22 January 1901, replaced by:https://www.wikidata.org/wiki/Q20875
P570/date of death 22 January 1901
P20/place of death Osborne House
P21/sex or gender] Q6581072/female

Descendants of Queen Victoria[edit]

# WikiData SPARQL Query
#
# Wolfgang Fahl 2018-01-06
#
# get childen of queen victoria
SELECT ?child ?childLabel ?genderLabel ?dob
WHERE {
#  
# child
# https://www.wikidata.org/wiki/Property:P40
# Queen Victoria
# https://www.wikidata.org/wiki/Q9439
  wd:Q9439 wdt:P40+ ?child.
# gender
# https://www.wikidata.org/wiki/Property:P21
  ?child wdt:P21 ?gender.
# date of birth
# https://www.wikidata.org/wiki/Property:P569         
  ?child wdt:P569 ?dob
  SERVICE wikibase:label { bd:serviceParam wikibase:language "en". }
}
ORDER BY ?dob

try it!

How Triples are stored in WikiData[edit]

Regular triple[edit]

The file "mwstore://local-backend/local-public/diagrams/archive/20241121192712!Diagrams_b5043b34adf1cf9f03cc7977c1ca015f.png" already exists.

WikiData Example Queen Victoria's father[edit]

The file "mwstore://local-backend/local-public/diagrams/archive/20241121192712!Diagrams_4518bd357041ffff2861a83f6e439ebc.png" already exists.

Regular triple[edit]

WikiData Example Queen Victoria's father[edit]

WikiData Example Queen Victoria's father (technically)[edit]

The file "mwstore://local-backend/local-public/diagrams/archive/20241121192713!Diagrams_69fe283f436719ba4ac4f42a40e7312c.png" already exists.

WikiData Example Queen Victoria's father (multiple languages)[edit]

The file "mwstore://local-backend/local-public/diagrams/archive/20241121192713!Diagrams_90128f27d667bfdf6f0c537a7aadb70d.png" already exists.

Queen Victoria's father SPARQL Query[edit]

# WikiData SPARQL Query
#
# Wolfgang Fahl 2018-01-06
# see also https://stackoverflow.com/a/48341522/1497139
#
# get father of queen victoria
SELECT ?queenVictoria ?queenVictoriaLabel ?fatherProperty ?fatherPropertyLabel ?father ?fatherLabel
WHERE {
#  
# father
# https://www.wikidata.org/wiki/Property:P42
# Queen Victoria
# https://www.wikidata.org/wiki/Q9439
VALUES (?queenVictoria) {(wd:Q9439)}
VALUES (?property) {(wdt:P22)}
?queenVictoria ?property ?father.
?fatherProperty wikibase:directClaim ?property
SERVICE wikibase:label { bd:serviceParam wikibase:language "fr". }
}

try it!

🖨 🚪