User:Succu/SPARQL
External IDs
editStatistic
editSELECT ?taxonRankLabelDe (COUNT(?taxonRankLabelDe) AS ?countOfTaxonRank) WHERE {
?item wdt:P842 ?fossilworksId . # Fossilworks ID
?item wdt:P105 ?taxonRank .
SERVICE wikibase:label {
bd:serviceParam wikibase:language "de" .
?taxonRank rdfs:label ?taxonRankLabelDe .
}
}
GROUP BY ?taxonRankLabelDe
ORDER BY DESC(?countOfTaxonRank)
Constraint violation: Unique value
editSELECT ?id (COUNT(?id) AS ?countOfId) (GROUP_CONCAT(?qId;SEPARATOR = ", ") AS ?qIds) WHERE {
?item wdt:P685 ?id .
BIND(str(?item) as ?url)
BIND(strafter(?url, "http://www.wikidata.org/entity/") as ?qId)
}
GROUP BY ?id
HAVING(?countOfId > 1)
ORDER BY DESC(?countOfId) ASC(xsd:integer(?id))
Basic taxon properties
editSELECT ?item ?taxonName ?rank ?parentName ?parentRank ?id ?idTaxonName WHERE {
?item wdt:P225 ?taxonName .
#?item wdt:P105 wd:Q7432 . # species
?item wdt:P105 wd:Q35409 . # family
BIND(wd:Q35409 AS ?rank) .
#?item wdt:P105 ?rank .
?item wdt:P171/wdt:P225 ?parentName .
?item wdt:P171/wdt:P105 ?parentRank .
?item wdt:P685 ?id . # NCBI id
?item p:P685 ?idStatement .
?idStatement prov:wasDerivedFrom ?ref .
#?ref pr:P248 wd:Q82494 . # National Center for Biotechnology Information
OPTIONAL {?ref pr:P225 ?idTaxonName} .
}
#ORDER BY ASC(?taxonName)
Urls
editSELECT ?item ?taxonName ?url ?urlBase ?urlId WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P1421 ?url1 . # P1348=AlgaeBase, P1421=GRIN, P1991=LPSN
#?item p:P1421 ?urlStatement .
#FILTER NOT EXISTS {
# ?urlStatement prov:wasDerivedFrom ?ref .
#}
BIND(str(?url1) as ?url)
BIND(if(contains(?url, "?"), strbefore(?url, "?"), ?url) as ?urlBase)
BIND(if(contains(?url, "?"), strafter(?url, "?"), ?url) as ?urlId)
}
#ORDER BY ASC(?taxonName)
LIMIT 1000
SELECT ?item ?id ?uri
WHERE
{
wd:P3591 wdt:P1630 ?formaterUrl .
?item wdt:P3591 ?id.
BIND(URI(REPLACE(?formaterUrl,'\\$1', ?id)) AS ?uri)
}
ORDER BY ASC(xsd:integer(?id))
LIMIT 100
Taxa
editGeneral
editBelongs taxon to a higher taxon
editSELECT ?item ?taxonName ?taxonRank ?higherParentName WHERE {
BIND("Panthera leo" AS ?taxonName)
#BIND(wd:Q7432 AS ?taxonRank) # species
BIND(wd:Q7377 AS ?higherParent) # Mammalia
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P225 ?higherParentName .
}
ASK {
BIND("Panthera leo" AS ?taxonName)
BIND(wd:Q7377 AS ?higherParent) # Mammalia
?item (wdt:P171)* ?higherParent .
}
Selflink
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P171 ?item .
}
Fossil taxa
editSELECT (count(*) as ?countOfFossilTaxa) WHERE {
?item wdt:P31 wd:Q23038290 .
}
SELECT ?itemLink ?qId ?taxonName ?deCommonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P1843 ?deCommonName .
FILTER(lang(?deCommonName) = 'de' )
BIND(str(?item) as ?url)
BIND(strafter(?url, "http://www.wikidata.org/entity/") as ?qId)
BIND(uri(concat("https://www.wikidata.org/wiki/",?qId)) AS ?itemLink)
}
ORDER BY ASC(?taxonName)
Somevalue / novalue
editTaxon name with somevalue
editSELECT ?item ?itemLabel WHERE {
?item wdt:P225 ?taxonName .
FILTER(ISBLANK(?taxonName))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?itemLabel)
Taxon rank with novalue
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item p:P105 [a wdno:P105] .
}
ORDER BY ASC(?taxonName)
Wikidata rank (Wikidata statement rank (Q21044622))
editPreferred
editTaxa with a preferred taxon name
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item p:P225 ?statement .
?statement wikibase:rank wikibase:PreferredRank .
}
ORDER BY ASC(?taxonName)
Taxa with a preferred taxon rank
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item p:P105 ?statement .
?statement wikibase:rank wikibase:PreferredRank .
}
Taxa with a preferred parent taxon
editSELECT ?item ?taxonName ?parentTaxon WHERE {
?item wdt:P225 ?taxonName .
?item p:P171 ?statement .
?statement wikibase:rank wikibase:PreferredRank .
?statement ps:P171/p:P225/ps:P225 ?parentTaxon .
}
Deprecated
editTaxa with a deprecated taxon name
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item p:P225 ?statement .
?statement wikibase:rank wikibase:DeprecatedRank .
}
Taxa with a deprecated taxon rank
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item p:P105 ?statement .
?statement wikibase:rank wikibase:DeprecatedRank .
}
Taxa with a deprecated parent taxon
editSELECT ?item ?taxonName ?parentTaxon WHERE {
?item wdt:P225 ?taxonName .
?item p:P171 ?statement .
?statement wikibase:rank wikibase:DeprecatedRank .
?statement ps:P171/p:P225/ps:P225 ?parentTaxon .
}
Possible issues
editRank and parent rank are the same
editSELECT ?item ?taxonName ?taxonRank ?parentTaxonRank WHERE {
#BIND(wd:Q7432 AS ?taxonRank) # species
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
?item wdt:P171/wdt:P105 ?parentTaxonRank .
FILTER(sameTerm(?parentTaxonRank, ?taxonRank))
}
ORDER BY ASC(?taxonName)
Missing rank
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P105 ?taxonRank }
FILTER(!bound(?taxonRank))
MINUS {?item rdf:type wdno:P105 }
}
Species with a family as parent taxon
editSELECT ?item ?taxonName ?parentTaxonName ?parentTaxonRank WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q7432 .
?item wdt:P171/wdt:P225 ?parentTaxonName .
?item wdt:P171/wdt:P105 ?parentTaxonRank .
FILTER(sameTerm(?parentTaxonRank, wd:Q35409)) # family
MINUS {
SELECT ?item ?taxonName ?parentTaxonName ?parentTaxonRank WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q7432 .
?item wdt:P171/wdt:P225 ?parentTaxonName .
?item wdt:P171/wdt:P105 ?parentTaxonRank .
?item (wdt:P171)* wd:Q808 . # virus
}
}
#FILTER(STRENDS(?parentTaxonName, "aceae")) # plant family ( "idae" animal family)
}
ORDER BY ASC(?parentTaxonName) ASC(?taxonName)
Subspecies with wrong parent species
editSELECT ?item ?taxonName ?parentTaxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q68947 . #subspecies
?item wdt:P171/wdt:P225 ?parentTaxonName .
FILTER (!strStarts(?taxonName, ?parentTaxonName))
}
ORDER BY ASC(?taxonName)
Misidentified subtribe
editSELECT ?item ?taxonName ?parentTaxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q2455704 . # subfamily (-inae)
?item wdt:P171/wdt:P225 ?parentTaxonName .
?item wdt:P171/wdt:P105 ?parentTaxonRank .
FILTER(sameTerm(?parentTaxonRank, wd:Q227936)) # tribe
}
ORDER BY ASC(?parentTaxonName) ASC(?taxonName)
Genera without child taxa
editSELECT ?item ?taxonName {
?item wdt:P105 wd:Q34740 .
MINUS { ?item ^wdt:P171 [] } .
#?item (wdt:P171)* wd:Q14560 . #parent taxon
OPTIONAL { ?item wdt:P225 ?taxonName } .
}
Plants with malformed subspecies names
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q68947 . #subspecies
?item (wdt:P171)* wd:Q11973077 . #Viridiplantae - timeout with plants
Filter(!regex(?taxonName, " subsp. "))
}
ORDER BY ASC(?item)
Plants with malformed variety names
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q767728 . #variety
?item (wdt:P171)* wd:Q11973077 . #Viridiplantae - timeout with plants
Filter(!regex(?taxonName, " var. "))
}
ORDER BY ASC(?item)
Malformed hybrid names
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
FILTER (CONTAINS(?taxonName, "× "))
}
ORDER BY ASC(?taxonName)
Incorrect family name
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q35409 . # family
FILTER(!(STRENDS(?taxonName, "idae") || STRENDS(?taxonName, "aceae")))
}
Incorrect subfamily name
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q2455704 . # subfamily
FILTER(!(STRENDS(?taxonName, "inae") || STRENDS(?taxonName, "oideae")))
}
Incorrect tribe name
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q227936 . # tribus
FILTER(!(STRENDS(?taxonName, "ini") || STRENDS(?taxonName, "eae")))
}
Misapplied has basionym (P566)
editSELECT ?item ?taxonName WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q729 . # Animalia
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P566 ?basionym .
?item wdt:P225 ?taxonName .
}
Misapplied original combination (P1403)
editSELECT ?item ?taxonName WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P1403 ?protonym .
?item wdt:P225 ?taxonName .
}
Misapplied P5326 (P5326)
editSELECT ?item ?taxonName ?title ?firstName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P5326/wdt:P1476 ?title .
OPTIONAL {?item wdt:P1403/wdt:P225 ?firstName} .
OPTIONAL {?item wdt:P566/wdt:P225 ?firstName} .
FILTER(BOUND(?firstName))
}
ORDER BY ASC(?taxonName)
SELECT ?item ?taxonName WHERE {
?item wdt:P566 ?basionym .
?item wdt:P1403 ?protonym .
?item wdt:P225 ?taxonName .
}
Missing original combination (P1403)
editSELECT ?item ?taxonName WHERE {
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pq:P31 ?isA .
OPTIONAL {?item wdt:P1403 ?protonym} .
FILTER(sameTerm(?isA, wd:Q14594740))
FILTER(!bound(?protonym))
}
ORDER BY ASC(?taxonName)
Wrong precision for year of publication of scientific name for taxon (P574)
editSELECT ?item ?taxonName ?timeprecision WHERE {
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pqv:P574 ?date .
?date wikibase:timePrecision ?timeprecision .
FILTER(?timeprecision != "9"^^xsd:integer)
}
ORDER BY DESC(?timeprecision) ASC(?taxonName)
Missing mandatory properties
editSELECT ?item ?taxonName ?taxonRank ?parentTaxon WHERE {
?item wdt:P31 wd:Q16521 . #taxon
OPTIONAL {?item wdt:P225 ?taxonName} .
OPTIONAL {?item wdt:P105 ?taxonRank} .
OPTIONAL {?item wdt:P171 ?parentTaxon} .
FILTER (!bound(?taxonName) || !bound(?taxonRank) || !bound(?parentTaxon))
}
#ORDER BY ?taxonName
LIMIT 2000
Duplicated pages
editSELECT ?item ?taxonName WHERE {
VALUES ?taxon {wd:Q16521 wd:Q310890 wd:Q23038290} . # taxon, monotypic taxon, fossil taxon
?item p:P31/ps:P31 wd:Q17362920 . # duplicated page
?item p:P31/pq:P642 ?duplicateItem . # von
#?item p:P31/pq:P460 ?duplicateItem . # said to be the same as
?duplicateItem p:P31/ps:P31 ?taxon .
?duplicateItem p:P225/ps:P225 ?taxonName .
}
ORDER BY ASC(?taxonName)
Duplicated Wikispecies pages
editSELECT ?item ?taxonName ?wikispeciesArticle WHERE {
VALUES ?taxon {wd:Q16521 wd:Q310890 wd:Q23038290} . # taxon, monotypic taxon, fossil taxon
?item p:P31/ps:P31 wd:Q17362920 . # duplicated page
?item p:P31/pq:P642 ?duplicateItem . # von
#?item p:P31/pq:P460 ?duplicateItem . # said to be the same as
?duplicateItem p:P31/ps:P31 ?taxon .
?duplicateItem p:P225/ps:P225 ?taxonName .
?article schema:about ?item ;
schema:isPartOf <https://species.wikimedia.org/> ;
schema:name ?wikispeciesArticle .
}
ORDER BY ASC(?taxonName)
Nomenclature related
editBelongs taxon to a nomenclatural Code
editSELECT DISTINCT ?item ?taxonName ?nomenclaturalCode WHERE {
BIND("Panthera leo" AS ?taxonName)
BIND(wd:Q13011 AS ?nomenclaturalCode) # ICZN=Q13011, ICNafp=Q693148, ICNCP=Q941761, ICNB=Q743780, ICVCN=Q14920640
?item wdt:P225 ?taxonName .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 ?nomenclaturalCode .
}
Taxon names qualified with original spelling (P1353)
editSELECT ?item ?taxonName ?originalSpelling WHERE {
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pq:P1353 ?originalSpelling .
}
ORDER BY ASC(?taxonName)
Taxon names qualified with nomenclatural status (P1135)
editSELECT ?item ?taxonName ?nomenclaturalStatusLabel WHERE {
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pq:P1135 ?nomenclaturalStatus .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?nomenclaturalStatusLabel) ASC(?taxonName)
Later homonym, nomen illegitimum ...
editSELECT ?item ?itemLabel ?kindOf WHERE {
{
?item wdt:P31 wd:Q17276484 . # later homonym
BIND("later homonym" AS ?kindOf) .
}
UNION {
?item wdt:P31 wd:Q1093954 . # nomen illegitimum
BIND("nomen illegitimum" AS ?kindOf) .
}
UNION {
?item wdt:P31 wd:Q17487588 . # unavailable for use
BIND("unavailable for use" AS ?kindOf) .
}
UNION {
?item wdt:P31 wd:Q15149791 . # nomen utique rejiciendum
BIND("nomen utique rejiciendum" AS ?kindOf) .
}
UNION {
?item wdt:P31 wd:Q28549151. # preoccupied name
BIND("preoccupied name" AS ?kindOf) .
}
SERVICE wikibase:label {
bd:serviceParam wikibase:language "en" .
?item rdfs:label ?itemLabel .
}
}
ORDER BY ?itemLabel
Synonyms
editList of basionyms (plantae, fungi) (has basionym (P566))
editSELECT ?item ?basionymName ?basionymOf WHERE {
?item wdt:P225 ?basionymOf .
#?item wdt:P105 wd:Q7432 . # species
?item wdt:P566/wdt:P225 ?basionymName .
#?item wdt:P566/wdt:P225 "Arequipa weingartiana" .
}
ORDER BY ASC(?basionymName)
SELECT DISTINCT ?item ?taxonName ?basionymOf WHERE {
?item wdt:P2868 wd:Q810198 . # basionym
?item wdt:P225 ?taxonName .
?item p:P2868 ?taxonNameStatement .
?taxonNameStatement pq:P642/wdt:P225 ?basionymOf
}
ORDER BY ASC(?taxonName) ASC(?basionymOf)
List of original combinations (animalia) (original combination (P1403))
editSELECT ?item ?taxonName ?combinedTo WHERE {
?item wdt:P225 ?combinedTo .
#?item wdt:P105 wd:Q7432 . # species
?item wdt:P1403/wdt:P225 ?taxonName .
#?item wdt:P1403/wdt:P225 "Bufo viridis" .
}
ORDER BY ASC(?taxonName)
List of replaced names (replaced synonym (for nom. nov.) (P694))
editSELECT ?item ?replacedName ?replacementOf WHERE {
?item wdt:P225 ?replacementOf .
#?item wdt:P105 wd:Q7432 . # species
?item wdt:P694/wdt:P225 ?replacedName .
#?item wdt:P694/wdt:P225 "Doronicum bellidiastrum" .
}
ORDER BY ASC(?replacedName)
List of synonyms (taxon synonym (P1420))
editSELECT ?item ?synonymName ?synonymOf WHERE {
?item wdt:P225 ?synonymOf .
#?item wdt:P225 "Oreocereus hempelianus" .
#?item wdt:P105 wd:Q7432 . # species
#?item (wdt:P171)* wd:Q14560 . # Cactaceae
?item wdt:P1420/wdt:P225 ?synonymName .
}
ORDER BY ASC(?synonymName)
Cacti
editList of all genera and species of cacti
editSELECT ?item ?name WHERE {
?item wdt:P225 ?name .
{
?item wdt:P105 wd:Q7432 .
} UNION {
?item wdt:P105 wd:Q34740 .
}
?item (wdt:P171)* wd:Q14560 .
}
ORDER BY ASC(?name)
List of all genera and species of cacti with articles in dewiki
editPREFIX schema: <http://schema.org/>SELECT ?item ?name ?article WHERE {
?item wdt:P225 ?name .
{
?item wdt:P105 wd:Q7432 .
} UNION {
?item wdt:P105 wd:Q34740 .
}
?item (wdt:P171)* wd:Q14560 .
OPTIONAL {
?article schema:about ?item .
?article schema:inLanguage "de" .
FILTER (SUBSTR(str(?article), 1, 25) = "https://de.wikipedia.org/")
}
}
ORDER BY ASC(?name)
List of cacti without german description
editSELECT ?item ?taxonName ?taxonRankLabel ?parentTaxonName (GROUP_CONCAT(?lang) AS ?langs) WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
?item wdt:P171/wdt:P225 ?parentTaxonName .
?item (wdt:P171)* wd:Q14560 . # Cactaceae
OPTIONAL {?item schema:description ?itemDescription}
BIND(lang(?itemDescription) as ?lang)
SERVICE wikibase:label {bd:serviceParam wikibase:language "de" .}
}
GROUP BY ?item ?taxonName ?taxonRankLabel ?parentTaxonName
HAVING (!Contains(?langs, "de"))
ORDER BY ASC(?taxonName)
List of cacti with their synonyms
editSELECT ?item ?taxonName ?synonymName WHERE {
?item wdt:P225 ?taxonName .
#?item wdt:P225 "Oreocereus hempelianus" . # only this species
#?item wdt:P105 wd:Q7432 . # species
?item (wdt:P171)* wd:Q14560 . # Cactaceae
?item wdt:P1420/wdt:P225 ?synonymName .
}
ORDER BY ASC(?taxonName)
List of cacti with their synonyms according to Das große Kakteen-Lexikon (Q13520496)
editBy accepted taxon name
editPREFIX p: <http://www.wikidata.org/prop/>
PREFIX q: <http://www.wikidata.org/prop/qualifier/>
PREFIX v: <http://www.wikidata.org/prop/statement/>
PREFIX pr: <http://www.wikidata.org/prop/reference/>PREFIX prov: <http://www.w3.org/ns/prov#> SELECT DISTINCT ?item ?acceptedTaxonName ?synonymName WHERE {
?item wdt:P225 ?acceptedTaxonName .
#?item wdt:P225 "Oreocereus hempelianus" . # only this species
#?item wdt:P105 wd:Q7432 . # species
?item (wdt:P171)* wd:Q14560 . # Cactaceae
?item wdt:P1420/wdt:P225 ?synonymName .
?synonymNameV v:P1420 ?synonymNameValue .
?synonymNameV prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q13520496 . # Das große Kakteen-Lexikon
#?ref pr:P248 wd:Q10695694 . # New Cactus Lexicon
}
ORDER BY ASC(?acceptedTaxonName)|
By synonym
editPREFIX p: <http://www.wikidata.org/prop/>
PREFIX q: <http://www.wikidata.org/prop/qualifier/>
PREFIX v: <http://www.wikidata.org/prop/statement/>
PREFIX pr: <http://www.wikidata.org/prop/reference/>PREFIX prov: <http://www.w3.org/ns/prov#> SELECT DISTINCT ?item ?synonymName ?synonymOf WHERE {
?item wdt:P225 ?synonymOf .
#?item wdt:P225 "Oreocereus hempelianus" .
#?item wdt:P105 wd:Q7432 . # species
?item (wdt:P171)* wd:Q14560 . # Cactaceae
?item wdt:P1420/wdt:P225 ?synonymName .
?synonymNameV v:P1420 ?synonymNameValue .
?synonymNameV prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q13520496 . # Das große Kakteen-Lexikon
#?ref pr:P248 wd:Q10695694 . # New Cactus Lexicon
}
ORDER BY ASC(?synonymName)|
Count of epithets
editSELECT DISTINCT ?epithet (COUNT(?epithet) AS ?countOfEpithet) WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q14560 . # Plantae - times out
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
BIND(strbefore(?taxonName, " ") as ?genus)
BIND(strafter(?taxonName, " ") as ?epithet)
}
GROUP BY ?epithet
ORDER BY DESC(?countOfEpithet) ASC(?epithet)
Referenced with a paper
editSELECT ?item ?taxonName ?referencedBy ?title ?pages ?bhl ?referenceHasRoleLabel WHERE {
BIND(wd:Q14560 AS ?higherParent)
?item (wdt:P171)* ?higherParent .
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement prov:wasDerivedFrom ?ref .
?ref pr:P248 ?referencedBy .
?referencedBy wdt:P31 wd:Q13442814 . #scientific article
?referencedBy wdt:P1476 ?title .
OPTIONAL {?ref pr:P304 ?pages}
OPTIONAL {?ref pr:P687 ?bhl}
OPTIONAL {?ref pr:P6184 ?referenceHasRole}
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?title) ASC(?pages)
Other
editSELECT ?item ?taxonName ?year (SUBSTR(?published1, 1, 10) as ?published) ?publishedIn ?title WHERE {
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pq:P574 ?date .
?taxonNameStatement prov:wasDerivedFrom ?ref .
OPTIONAL {?ref pr:P248/wdt:P1476 ?title} .
OPTIONAL {?ref pr:P248/wdt:P577 ?published1} .
OPTIONAL {?ref pr:P248/wdt:P1433/wdt:P1476 ?publishedIn} .
BIND(xsd:integer(YEAR(?date)) as ?year)
#Filter(?year >= 2000)
Filter(?year = 2016)
#Filter(?year >= 2017)
}
ORDER BY DESC(?year) ASC(?taxonName)
Year in which Linnè described a species
editSELECT ?item ?taxonName (YEAR(?date) as ?year) WHERE {
?item p:P105/ps:P105 wd:Q7432 . # Species
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pq:P405 wd:Q1043. # Carl von Linnè
OPTIONAL {?taxonNameStatement pq:P574 ?date}
}
ORDER BY ASC(?taxonName)
Species with a reference to Linnès Species Plantarum. 1st Edition (Q21856050)
editSELECT ?item ?name ?volume ?pages WHERE {
VALUES ?sp {wd:Q21856106 wd:Q21856107} . # Species Plantarum, 1st Ed., Vol. 1+2
?item wdt:P225 ?name .
?item wdt:P105 wd:Q7432 .
?item p:P225 ?taxonName .
?taxonName ps:P225 ?taxonNameValue .
?taxonName pq:P405 wd:Q1043.
?taxonName prov:wasDerivedFrom ?ref .
?ref pr:P248 ?sp .
OPTIONAL {?ref pr:P304 ?pages}
BIND(if(sameTerm(?sp, wd:Q21856106), "1", "2") as ?volume)
BIND(REPLACE(?pages, "-", "–") AS ?pages)
BIND(REPLACE(?pages, "\\[1230\\]", "1230") AS ?pages)
BIND(REPLACE(?pages, "\\[1231\\]", "1231") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
}
ORDER BY ASC(xsd:integer(?startpage)) ASC(?name)
#ORDER BY ASC(?name)|
Species from Linnès Species Plantarum. 1st Edition (Q21856050) used as has basionym (P566)
editSELECT ?basionymItem ?basionym (GROUP_CONCAT(?basionymOf;SEPARATOR = ", ") AS ?basionymOfList) WHERE {
VALUES ?sp {wd:Q21856106 wd:Q21856107} . # Species Plantarum, 1st ed., Vol. 1+2
?item wdt:P566 ?basionymItem .
?item wdt:P105 wd:Q7432 . # species
?item wdt:P225 ?basionymOf .
#?item p:P225 ?taxonNameStatement .
#?taxonNameStatement pq:P405 [] .
?basionymItem p:P225 ?basionymNameStatement .
?basionymNameStatement ps:P225 ?basionym .
?basionymNameStatement pq:P405 wd:Q1043 . # Linné
?basionymNameStatement prov:wasDerivedFrom ?ref .
?ref pr:P248 ?sp .
}
GROUP BY ?basionymItem ?basionym
ORDER BY ASC(?basionym)
Genera with a reference to Linnès Genera Plantarum (Q40975586)
editSELECT ?item ?name ?pages ?bhlLink WHERE {
?item wdt:P225 ?name .
?item wdt:P105 wd:Q34740 .
?item p:P225 ?taxonName .
?taxonName ps:P225 ?taxonNameValue .
?taxonName pq:P405 wd:Q1043.
?taxonName prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q40975586 .
OPTIONAL {?ref pr:P304 ?pages}
OPTIONAL {?ref pr:P687 ?bhl}
BIND(REPLACE(?pages, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
BIND(uri(concat("http://biodiversitylibrary.org/page/",?bhl)) as ?bhlLink)
}
ORDER BY ASC(?name)
Taxa with a reference to Squirrels of the World (Q19597701)
editSELECT ?item ?taxonName ?pages WHERE {
?item p:P225 ?statement .
?statement ps:P225 ?taxonName .
?statement prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q19597701 . # Squirrels of the World
OPTIONAL {?ref pr:P304 ?pages}
}
ORDER BY ASC(?taxonName)
Publications
editJournals
editSELECT ?item ?doi ?zoobankpub (SUBSTR(?published1, 1, 10) as ?published) ?volume ?issue ?pages ?title WHERE {
?item wdt:P1433 wd:Q219980 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P2007 ?zoobankpub} .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(strbefore(?pages, "–") as ?startpage)
BIND(strafter(?pages, "–") as ?endpage)
}
ORDER BY ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
Articles
editSELECT ?item ?doi (SUBSTR(?published1, 1, 10) as ?published) ?issue ?pages ?title WHERE {
?item wdt:P1433 wd:Q14537320 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(strbefore(?pages, "–") as ?startpage)
BIND(strafter(?pages, "–") as ?endpage)
}
ORDER BY ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
Nomenclatural acts
editSELECT ?item ?taxonName ?state ?publication ?title {
?item p:P225 ?statement .
?statement ps:P225 ?taxonName .
?statement pq:P574 ?date .
?statement prov:wasDerivedFrom ?refnode .
?refnode pr:P248 ?ref
OPTIONAL {?refnode pr:P304 ?page }
OPTIONAL {?refnode pr:P6184 ?state_}
?ref wdt:P1433 wd:Q14537320 .
?ref wdt:P478 ?volume .
?ref wdt:P433 ?issue .
?ref wdt:P304 ?pages_ .
OPTIONAL {?ref wdt:P1476 ?title} .
BIND(if(!BOUND(?date), "", xsd:string(YEAR(?date))) as ?year)
BIND(if(sameTerm(?state_, wd:Q1361864), "tax. nov.", if(sameTerm(?state_, wd:Q14594740), "comb. nov.", if(sameTerm(?state_, wd:Q749462), "nom. nov.", ""))) as ?state)
BIND(CONCAT("PhytoKeys ", CONCAT(?issue, CONCAT(": ", CONCAT(?page, CONCAT(". ", ?year))))) AS ?publication)
FILTER(bound(?state))
}
ORDER BY ASC(?taxonName)
SELECT ?item ?doi (SUBSTR(?published1, 1, 10) as ?published) ?volume ?pages ?title WHERE {
?item wdt:P1433 wd:Q21386351 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(strbefore(?pages, "–") as ?startpage)
BIND(strafter(?pages, "–") as ?endpage)
}
ORDER BY ASC(xsd:integer(?volume)) ASC(xsd:integer(?startpage))
SELECT ?item ?doi (SUBSTR(?published1, 1, 10) as ?published )?volume ?issue ?pages ?articleId ?title WHERE {
?item wdt:P1433 wd:Q19370769 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages} .
OPTIONAL {?item wdt:P2322 ?articleId} .
OPTIONAL {?item wdt:P1476 ?title} .
}
ORDER BY ASC(xsd:integer(?issue)) ASC(xsd:integer(?published))
SELECT ?item ?doi ?zoobankpub (SUBSTR(?published1, 1, 10) as ?published) ?volume ?issue ?pages ?title WHERE {
?item wdt:P1433 wd:Q4037265 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P2007 ?zoobankpub} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(strbefore(?pages, "–") as ?startpage)
BIND(strafter(?pages, "–") as ?endpage)
FILTER (strStarts(?doi, "10.3897/DEZ"))
}
ORDER BY ASC(xsd:integer(?volume)) ASC(xsd:integer(?startpage))
Articles
editSELECT ?item ?doi ?zoobankpub (substr(?published1, 1, 10) as ?published )?volume ?issue ?pages ?title WHERE {
?item wdt:P1433 wd:Q220370 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P2007 ?zoobankpub} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(replace(?pages0, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
}
ORDER BY ASC(xsd:integer(?volume)) ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
Number of articles by year
editSELECT DISTINCT ?year (COUNT(?item) AS ?articles) WHERE {
?item wdt:P1433 wd:Q220370 .
OPTIONAL {?item wdt:P577 ?published} .
BIND(xsd:integer(YEAR(?published)) as ?year)
}
GROUP BY ?year
ORDER BY ASC(?year)
Wrong publication date precision
editSELECT ?item (substr(?published1, 1, 10) as ?published) ?publishedNode ?timeprecision WHERE {
?item wdt:P31 wd:Q13442814 .
?item wdt:P1433 wd:Q220370 .
?item p:P577/ps:P577 ?published .
?item p:P577/psv:P577 ?publishedValueNode .
?publishedValueNode wikibase:timePrecision ?timeprecision .
FILTER(?timeprecision != "11"^^xsd:integer)
}
SELECT ?item ?doi (substr(?published1, 1, 10) as ?published )?volume ?issue ?pages ?title WHERE {
?item wdt:P1433 wd:Q4807825.
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(replace(?pages0, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
}
ORDER BY ASC(xsd:integer(?volume)) ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
Articles
editSELECT ?item (SUBSTR(?published1, 1, 10) as ?published )?volume ?issue ?pages ?doi ?jstor ?title WHERE {
?item wdt:P1433 wd:Q2003024 . # Taxon
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P356 ?doi} .
OPTIONAL {?item wdt:P888 ?jstor} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
FILTER (strStarts(?title, "("))
}
ORDER BY ASC(?published) ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
Search
edit# Find title by volume, issue and page
SELECT ?item (SUBSTR(?published1, 1, 10) as ?published) ?title ?volume ?issue ?pages WHERE {
?item wdt:P1433 wd:Q2003024 . # Taxon
BIND("26" as ?volume) .
#BIND("2-3" as ?issue) .
BIND("326" as ?page) .
BIND("1977" as ?year) .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P1476 ?title} .
?item wdt:P478 ?volume .
?item wdt:P433 ?issue .
?item wdt:P304 ?pages0 .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
FILTER (xsd:integer(?page) >= xsd:integer(?startpage) && xsd:integer(?page) <= xsd:integer(?endpage))
FILTER (Year(?published1) = xsd:integer(?year))
}
ORDER BY ASC(?published) ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
Nomenclatural acts
editSELECT ?item ?taxonName ?state ?publication ?title {
?item p:P225 ?statement .
?statement ps:P225 ?taxonName .
?statement pq:P574 ?date .
?statement prov:wasDerivedFrom ?refnode .
?refnode pr:P248 ?ref
OPTIONAL {?refnode pr:P304 ?page }
OPTIONAL {?refnode pr:P6184 ?state_} ?ref wdt:P1433 wd:Q2003024 .
?ref wdt:P478 ?volume .
?ref wdt:P433 ?issue .
?ref wdt:P304 ?pages_ .
OPTIONAL {?ref wdt:P1476 ?title} .
BIND(if(!BOUND(?date), "", xsd:string(YEAR(?date))) as ?year)
BIND(if(sameTerm(?state_, wd:Q1361864), "tax. nov.", if(sameTerm(?state_, wd:Q14594740), "comb. nov.", if(sameTerm(?state_, wd:Q749462), "nom. nov.", ""))) as ?state)
BIND(CONCAT("Taxon ", CONCAT(?volume, CONCAT( "(",CONCAT(?issue, CONCAT("): ", CONCAT(?page, CONCAT(". ", ?year))))))) AS ?publication)
FILTER(bound(?state))
}
ORDER BY ASC(?taxonName)
SELECT ?item (SUBSTR(?published1, 1, 10) as ?published )?volume ?issue ?pages ?doi ?lang ?title WHERE {
?item wdt:P1433 wd:Q5550932 .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue0} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P356 ?doi} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(LANG(?title) AS ?lang)
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(REPLACE(?issue0, "-", "–") AS ?issue)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
BIND(if(contains(?issue, "–"), strbefore(?issue, "–"), ?issue) as ?startissue)
#FILTER (strStarts(?title, "("))
}
ORDER BY ASC(xsd:integer(?volume)) ASC(xsd:integer(?startissue)) ASC(xsd:integer(?startpage))
SELECT ?item ?doi ?zoobankpub (substr(?published1, 1, 10) as ?published) ?issue ?pages ?title WHERE {
?item wdt:P1433 wd:Q21386186 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P2007 ?zoobankpub} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(replace(?pages0, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
}
ORDER BY ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
Iczn
editDirections and Opinions
editSELECT ?item (SUBSTR(?published1, 1, 4) as ?published) ?title WHERE {
VALUES ?iczn {wd:Q6130489 wd:Q31205884 wd:Q15759939} . # Q6130489 = Smithsonian Miscellaneous Collections, Q31205884 = Opinions and declarations, Q15759939 = Bulletin of Zoological Nomenclature
?item wdt:P1433 ?iczn .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P1476 ?title} .
OPTIONAL {?item wdt:P687 ?bhlPage} .
BIND(strbefore(?title, " ") as ?type)
BIND(strafter(?title, " ") as ?tmp)
BIND(strbefore(?tmp, " ") as ?number)
BIND(replace(?number, "\\.", "") AS ?number)
BIND(replace(?number, ":", "") AS ?number)
BIND(replace(?number, ",", "") AS ?number)
FILTER (xsd:string(?type) = "Opinion" || xsd:string(?type) = "Direction")
FILTER (isNumeric(xsd:integer(?number)))
}
ORDER BY ASC(?type) ASC(xsd:integer(?number))
Taxonomic literature : a selective guide to botanical publications and collections with dates, commentaries and types (Q56649865)
editSELECT ?item ?idString ?id ?ipniId ?title WHERE {
?item wdt:P5878 ?idString .
OPTIONAL {?item wdt:P2008 ?ipniId} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?idString, "\\.", "") AS ?id)
#FILTER(CONTAINS(?idString, "."))
}
ORDER BY ASC(xsd:integer(?id))
BHL page ID (P687): Usage as property
editSELECT ?instanceOf (COUNT(?instanceOf) AS ?instanceOfCount) ?instanceOfLabel WHERE {
?item wdt:P687 ?pageId .
?item wdt:P31 ?instanceOf .
OPTIONAL {?instanceOf rdfs:label ?instanceOfLabel . FILTER(lang(?instanceOfLabel)="en") }
}
GROUP BY ?instanceOf ?instanceOfCount ?instanceOfLabel
ORDER BY DESC(?instanceOfCount)
BHL page ID (P687): Usage in reference
editSELECT ?item ?taxonName ?bhlPageId {
?item p:P225 ?statement .
?statement ps:P225 ?taxonName .
?statement prov:wasDerivedFrom ?refnode .
?refnode pr:P687 ?bhlPageId
}
ORDER BY ASC(?taxonName)
BHL bibliography ID (P4327): Usage
editSELECT ?instanceOf (COUNT(?instanceOf) AS ?instanceOfCount) ?instanceOfLabel WHERE {
?item wdt:P4327 ?publicationId .
?item wdt:P31 ?instanceOf .
OPTIONAL {?instanceOf rdfs:label ?instanceOfLabel . FILTER(lang(?instanceOfLabel)="en")}
}
GROUP BY ?instanceOf ?instanceOfCount ?instanceOfLabel
ORDER BY DESC(?instanceOfCount)
SELECT ?item ?publicationId ?title (YEAR(?published) as ?year) ?instanceOfLabel WHERE {
?item wdt:P4327 ?publicationId .
?item wdt:P31 ?instanceOf .
OPTIONAL {?item wdt:P1476 ?title} .
OPTIONAL {?item wdt:P577 ?published} .
OPTIONAL {?instanceOf rdfs:label ?instanceOfLabel . FILTER(lang(?instanceOfLabel)="en")}
#BIND(wd:Q732577 AS ?publicationType) # publication
BIND(wd:Q5633421 AS ?publicationType) # scientific journal
FILTER(sameTerm(?instanceOf, ?publicationType))
}
ORDER BY ASC(?instanceOfLabel) ASC(?title)
BHL creator ID (P4081): Usage
editSELECT ?instanceOf (COUNT(?instanceOf) AS ?instanceOfCount) ?instanceOfLabel WHERE {
?item wdt:P4081 ?creatorId .
?item wdt:P31 ?instanceOf .
OPTIONAL {?instanceOf rdfs:label ?instanceOfLabel . FILTER(lang(?instanceOfLabel)="en")}
}
GROUP BY ?instanceOf ?instanceOfCount ?instanceOfLabel
ORDER BY DESC(?instanceOfCount)
BHL creator ID (P4081): List
editSELECT DISTINCT ?item ?itemLabel (GROUP_CONCAT(?creatorId;SEPARATOR = ", ") AS ?creatorIds) ?ipniAuthorId WHERE {
?item wdt:P4081 ?creatorId .
?item wdt:P31 ?instanceOf .
OPTIONAL {?item wdt:P586 ?ipniAuthorId} .
OPTIONAL {?item rdfs:label ?itemLabel . FILTER(lang(?itemLabel)="en")}
BIND(wd:Q5 AS ?creatorType) # human
FILTER(sameTerm(?instanceOf, ?creatorType))
}
GROUP BY ?item ?itemLabel ?ipniAuthorId
Other stuff
editJournals publishing articles with a DOI (P356)
editSELECT DISTINCT ?title ?title_old WHERE {
?item wdt:P356 ?doi .
?item wdt:P1433/wdt:P1476 ?title .
OPTIONAL {?item wdt:P1433/wdt:P357 ?title_old } .
}
ORDER BY ASC(?title)
Top 100 of author name string (P2093)
editSELECT DISTINCT ?shortname ?no_shortname WHERE {
?item wdt:P2093 ?shortname .
{
SELECT ?shortname (COUNT(?shortname) AS ?no_shortname) WHERE {
?item wdt:P2093 ?shortname .
}
GROUP BY ?shortname
HAVING(?no_shortname > 1)
}
}
ORDER BY DESC(?no_shortname)
LIMIT 100
Title with possible HTML tags
editSELECT ?item ?title WHERE {
{
?item wdt:P356 ?doi .
?item wdt:P1476 ?title.
}
UNION {
?item wdt:P356 ?doi .
?item wdt:P357 ?title .
}
Filter(contains(?title, "<") || contains(?title, ">"))
}
ORDER BY ASC(?title)
SELECT ?item ?doi WHERE {
?item wdt:P356 ?doi .
?item wdt:P31 wd:Q13442814 .
OPTIONAL {?item wdt:P1433 ?publishedIn} .
FILTER (!bound(?publishedIn))
}
ORDER BY ASC(?doi)
DOI in reference of taxon name (P225)
editSELECT ?item ?taxonName ?doi ?statedIn WHERE {
?item p:P225 ?idStatement .
?item p:P225/ps:P225 ?taxonName .
?idStatement prov:wasDerivedFrom ?ref .
?ref pr:P356 ?doi .
OPTIONAL {?ref pr:P248 ?statedIn} .
FILTER(!bound(?statedIn))
#FILTER(bound(?statedIn) && !sameTerm(?statedIn, wd:Q13711410))
}
ORDER BY ASC(?taxonName)
reference has role (P6184) (Statistic)
editSELECT DISTINCT ?role ?roleLabel (COUNT(?roleLabel) AS ?countOfRoleLabel) WHERE {
?item p:P225/ps:P225 ?taxonName .
?item p:P225 ?taxonNameStatement .
?taxonNameStatement prov:wasDerivedFrom ?ref .
?ref pr:P6184 ?role
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE], en". }
}
GROUP BY ?role ?roleLabel ?countOfRoleLabel
ORDER BY DESC(?countOfRoleLabel)
reference has role (P6184) (List)
editSELECT DISTINCT ?item ?taxonName WHERE {
?item p:P225/ps:P225 ?taxonName .
?item p:P225 ?taxonNameStatement .
?taxonNameStatement prov:wasDerivedFrom ?ref .
?ref pr:P6184 wd:Q14594740 #role=recombination
}
ORDER BY ASC(?taxonName)
Authors
editSimple list
editSELECT * WHERE {
?item wdt:P428 ?authorabbrev .
}
ORDER BY ASC(?authorabbrv)
Count
editSELECT (count(*) as ?count) WHERE {
?item wdt:P428 ?authorabbrv .
}
Extended list
editSELECT ?item ?authorabbrv ?itemLabelDe (SUBSTR(?birthdate1, 1, 10) as ?birthdate) (SUBSTR(?deathdate1, 1, 10) as ?deathdate) WHERE {
?item wdt:P428 ?authorabbrv .
OPTIONAL {?item wdt:P569 ?birthdate1} .
OPTIONAL {?item wdt:P570 ?deathdate1} .
SERVICE wikibase:label {
bd:serviceParam wikibase:language "de" .
?item rdfs:label ?itemLabelDe .
}
}
ORDER BY ASC(?authorabbrv)
Extended list (only with articles to dewiki)
editSELECT ?item ?authorabbrv ?itemLabelDe (SUBSTR(?birthdate1, 1, 10) as ?birthdate) (SUBSTR(?deathdate1, 1, 10) as ?deathdate) ?article WHERE {
?item wdt:P428 ?authorabbrv .
?article schema:about ?item .
?article schema:inLanguage "de" .
FILTER (SUBSTR(str(?article), 1, 25) = "https://de.wikipedia.org/")
OPTIONAL {?item wdt:P569 ?birthdate1} .
OPTIONAL {?item wdt:P570 ?deathdate1} .
SERVICE wikibase:label {
bd:serviceParam wikibase:language "de" .
?item rdfs:label ?itemLabelDe .
}
}
ORDER BY ASC(?authorabbrv)
Possible issues with birth- and/or deathdate
editSELECT ?item ?authorabbrv ?itemLabelDe (SUBSTR(?birthdate1, 1, 10) as ?birthdate) (SUBSTR(?deathdate1, 1, 10) as ?deathdate) WHERE {
?item wdt:P428 ?authorabbrv .
OPTIONAL {?item wdt:P569 ?birthdate1} .
OPTIONAL {?item wdt:P570 ?deathdate1} .
SERVICE wikibase:label {
bd:serviceParam wikibase:language "de" .
?item rdfs:label ?itemLabelDe .
}
{
SELECT ?authorabbrv (COUNT(?authorabbrv) AS ?no_authorabbrv) WHERE {
?item wdt:P428 ?authorabbrv .
OPTIONAL {?item wdt:P569 ?birthdate} .
OPTIONAL {?item wdt:P570 ?deathdate} .
}
GROUP BY ?authorabbrv
HAVING(?no_authorabbrv > 1)
}
}
ORDER BY ASC(?authorabbrv)
Missing IPNI author ID (P586) in reference
editSELECT ?item ?authorAbbrev (SUBSTR(?birthdate1, 1, 4) as ?birthyear) (SUBSTR(?deathdate1, 1, 4) as ?deathyear) WHERE {
?item wdt:P428 ?authorAbbrev .
?item p:P428 ?authorabbrev1 .
?authorabbrev1 ps:P428 ?authorabbrevValue .
?authorabbrev1 prov:wasDerivedFrom ?ref .
OPTIONAL {?ref pr:P586 ?authorId} .
OPTIONAL {?item wdt:P569 ?birthdate1} .
OPTIONAL {?item wdt:P570 ?deathdate1} .
FILTER (!bound(?authorId))
}
ORDER BY ASC(?authorAbbrev)
TODO
Etymology
editSELECT DISTINCT ?item ?taxonName ?pages ?namedAfterLabel {
?item wdt:P138 ?namedAfter .
?item wdt:P225 ?taxonName .
?item p:P138 ?statement .
?statement prov:wasDerivedFrom ?refnode .
?refnode pr:P248 ?ref
OPTIONAL {?refnode pr:P304 ?pages }
FILTER(sameTerm(?ref, wd:Q21500983)) #Etymological Dictionary of Succulent Plant Names
BIND(REPLACE(?pages, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(xsd:integer(?startpage)) ASC(?taxonName)
Name is used as noun (Q1084)
editName ends with vowel (Q36244) or with -er
edit-i (Male (sex or gender (P21) = male (Q6581097)))
editSELECT ?item ?taxonName ?personLabel ?genderLabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P138 ?person} .
OPTIONAL {?item wdt:P138/wdt:P21 ?gender} .
FILTER((STRENDS(?taxonName, "i") && !STRENDS(?taxonName, "ii")))
FILTER(bound(?person))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
-ae (Female (sex or gender (P21)=female (Q6581072))
editSELECT ?item ?taxonName ?personLabel ?genderLabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P138 ?person} .
OPTIONAL {?item wdt:P138/wdt:P21 ?gender} .
FILTER((STRENDS(?taxonName, "ae") && !STRENDS(?taxonName, "iae")))
FILTER(bound(?person))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
TODO: Exception 1 - Single persons, ends with -a becomes -ae
editTODO: Exception 2 - Multiple persons, ends with -a becomes -arum
editName ends with consonant (Q38035), but not with -er
edit-ii (Male sex or gender (P21)=male (Q6581097))
editSELECT ?item ?taxonName ?personLabel ?genderLabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P138 ?person} .
OPTIONAL {?item wdt:P138/wdt:P21 ?gender} .
FILTER((STRENDS(?taxonName, "ii")))
FILTER(bound(?person))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
-iae (Female (sex or gender (P21)=female (Q6581072))
editSELECT ?item ?taxonName ?personLabel ?genderLabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P138 ?person} .
OPTIONAL {?item wdt:P138/wdt:P21 ?gender} .
FILTER((STRENDS(?taxonName, "iae")))
FILTER(bound(?person))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
-iorum (Multiple males or a married couple (married couple (Q3046146)))
editSELECT ?item ?taxonName ?personLabel ?isALabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P138 ?person} .
OPTIONAL {?item wdt:P138/wdt:P31 ?isA} .
FILTER((STRENDS(?taxonName, "iorum")))
FILTER(bound(?person))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
-iarum (Multiple females)
editSELECT ?item ?taxonName ?personLabel ?genderLabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
#?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P138 ?person} .
OPTIONAL {?item wdt:P138/wdt:P21 ?gender} .
FILTER((STRENDS(?taxonName, "iarum")))
FILTER(bound(?person))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
Name is used as adjective (Q34698)
editNomenclatural codes (nomenclature code (Q2673092))
editAppendices
edit# opera utique oppressa
SELECT ?item ?title WHERE {
?item p:P31 ?taxonNameStatement .
?taxonNameStatement prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q65690812 .
?item wdt:P1476 ?title .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?title)
Appendix IIA: Conserved, protected, and rejected names of families of algae, fungi, pteridophytes, and fossils (Q65681854)
editTODO
Appendix IIB: Conserved and rejected names of families of bryophytes and spermatophytes (Q65682475)
editSELECT ?item ?taxonName ?nomenclaturalStatusLabel ?typeGenus ?typeGenusName ?typeSpeciesName ?typeSpeciesRoleLabel WHERE {
?item wdt:P105 wd:Q35409 . # family
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pq:P1135 ?nomenclaturalStatus .
?taxonNameStatement prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q65682475 . # Appendix IIB
OPTIONAL {?item wdt:P427 ?typeGenus} .
OPTIONAL {?item wdt:P427/wdt:P225 ?typeGenusName} .
OPTIONAL {?typeGenus wdt:P427 ?typeSpecies} .
OPTIONAL {?typeGenus wdt:P427/wdt:P225 ?typeSpeciesName} .
OPTIONAL {?typeGenus p:P427/pq:P3831 ?typeSpeciesRole} .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
#FILTER(!bound(?typeSpecies))
#MINUS {?typeGenus rdf:type wdno:P427}
}
ORDER BY ASC(?taxonName)
Appendix III: Conserved, protected, and rejected names of genera and subdivisions of genera (Q65706483)
editSELECT ?item ?taxonName ?nomenclaturalStatusLabel ?typeSpeciesName ?typeSpeciesRoleLabel WHERE {
?item wdt:P105 wd:Q34740 . # genus
?item p:P225 ?taxonNameStatement .
?taxonNameStatement ps:P225 ?taxonName .
?taxonNameStatement pq:P1135 ?nomenclaturalStatus .
?taxonNameStatement prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q65706483 . # Appendix III
OPTIONAL {?item wdt:P427 ?typeSpecies} .
OPTIONAL {?item wdt:P427/wdt:P225 ?typeSpeciesName} .
OPTIONAL {?item p:P427/pq:P3831 ?typeSpeciesRole} .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
#FILTER(!bound(?typeSpecies))
#MINUS {?typeSpecies rdf:type wdno:P427}
}
ORDER BY ASC(?taxonName)
Appendix IV: Conserved, protected, and rejected names of species and infraspecific taxa (Q65706487)
editTODO
TODO
TODO
TODO
Herbaria
editSELECT ?item ?indexHerbariumId WHERE {
?item wdt:P5858 ?indexHerbariumId .
}
ORDER BY ASC(?indexHerbariumId)
Types
editSpecies
editSELECT ?item ?taxonName ?nomenclaturalType ?nomenclaturalTypeLabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
?item wdt:P427 ?nomenclaturalType .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
Genera
editSELECT ?item ?taxonName ?nomenclaturalType WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
?item wdt:P105 wd:Q34740 .
?item wdt:P225 ?taxonName .
?item wdt:P427/wdt:P225 ?nomenclaturalType .
}
ORDER BY ASC(?taxonName)
SELECT ?item ?taxonName ?nomenclaturalType WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in Q764 . # Fungi
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
?item wdt:P105 wd:Q34740 .
?item wdt:P225 ?taxonName .
?item wdt:P427/wdt:P225 ?nomenclaturalType .
}
ORDER BY ASC(?taxonName)
Autonyms (autonym (Q1837887))
editSubspecies
editSELECT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q68947 . #subspecies
FILTER(REGEX(?taxonName, "\\b(\\w+) subsp. (\\1)\\b")) #todo replace w+
#FILTER(REGEX(?taxonName, "\\b(\\w+) (\\1)\\b"))
}
ORDER BY ASC(?taxonName)
Species with only a single subspecies
editSELECT ?speciesName (COUNT(?speciesName) AS ?countOfSpeciesName) (GROUP_CONCAT(?taxonName;SEPARATOR = ", ") AS ?taxonNames) WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q68947 . #subspecies
FILTER(REGEX(?taxonName, " subsp. "))
BIND(STRBEFORE(?taxonName, " subsp.") as ?speciesName)
}
GROUP BY ?speciesName
HAVING(?countOfSpeciesName = 1)
ORDER BY ASC(?countOfSpeciesName) ASC(?speciesName)
Subspecies autonyms with author
editSELECT ?item ?taxonName WHERE {
?item p:P105/ps:P105 wd:Q68947 . # subspecies
?item p:P225/ps:P225 ?taxonName .
?item p:P225/pq:P405 [] .
FILTER(REGEX(?taxonName, "\\b(\\w+) subsp. (\\1)\\b")) #todo replace w+
}
ORDER BY ASC(?taxonName)
Types
editSpecies
editSELECT ?item ?taxonName ?nomenclaturalType ?nomenclaturalTypeLabel WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q729 . # Animalia
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
?item wdt:P427 ?nomenclaturalType .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ASC(?taxonName)
Genera
editSELECT ?item ?taxonName ?nomenclaturalType WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q729 . # Animalia
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
?item wdt:P105 wd:Q34740 .
?item wdt:P225 ?taxonName .
?item wdt:P427/wdt:P225 ?nomenclaturalType .
}
ORDER BY ASC(?taxonName)
Taxa
editSELECT DISTINCT ?item ?taxonName ?taxonRankLabel WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?taxonName)
Ranks
editSELECT DISTINCT ?taxonRankLabel (COUNT(?taxonRankLabel) AS ?countOfTaxonRank) WHERE {
?item wdt:P105 ?taxonRank .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
GROUP BY ?taxonRankLabel
ORDER BY DESC(?countOfTaxonRank)
Strains
editSELECT ?item ?taxonName ?taxonRankLabel ?parentTaxon WHERE {
?item wdt:P31 wd:Q855769 .
OPTIONAL {?item wdt:P225 ?taxonName} .
OPTIONAL {?item wdt:P105 ?taxonRank} .
OPTIONAL {?item wdt:P171/wdt:P225 ?parentTaxon} .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC (?taxonName)
Culture Collections
editSELECT ?item ?itemLabel ?shortName WHERE {
?item wdt:P31 wd:Q64062850 .
OPTIONAL {?item wdt:P1813 ?shortName} .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?shortName)
Publications
editNotifications
editSELECT ?item (SUBSTR(?published1, 1, 10) as ?published )?volume ?issue ?pages ?doi ?pubMedId ?title WHERE {
VALUES ?journalItems {wd:Q26827892 wd:Q26827884 wd:Q3511931} .
?item wdt:P1433 ?journalItems .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P356 ?doi} .
OPTIONAL {?item wdt:P698 ?pubMedId} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
FILTER (contains(lcase(?title), "notification that new names"))
}
ORDER BY ASC(?published) ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
gen. nov. / sp. nov. / subsp. nov. / comb. nov. / Candidatus
editSELECT ?item (SUBSTR(?published1, 1, 10) as ?published )?volume ?issue ?pages ?doi ?pubMedId ?title WHERE {
VALUES ?journalItems {wd:Q26827892 wd:Q26827884 wd:Q3511931} .
?item wdt:P1433 ?journalItems .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P356 ?doi} .
OPTIONAL {?item wdt:P698 ?pubMedId} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(if(contains(?pages, "–"), strbefore(?pages, "–"), ?pages) as ?startpage)
BIND(if(contains(?pages, "–"), strafter(?pages, "–"), ?pages) as ?endpage)
FILTER (contains(lcase(?title), "gen. nov."))
#FILTER (contains(lcase(?title), "sp. nov."))
#FILTER (contains(lcase(?title), "subsp. nov."))
#FILTER (contains(lcase(?title), "comb. nov."))
#FILTER (contains(lcase(?title), "candidatus"))
}
ORDER BY ASC(?published) ASC(xsd:integer(?issue)) ASC(xsd:integer(?startpage))
SELECT ?item ?doi (SUBSTR(?published1, 1, 10) as ?published) ?pages ?title WHERE {
?item wdt:P1433 wd:Q55953029 .
?item wdt:P356 ?doi .
OPTIONAL {?item wdt:P577 ?published1} .
OPTIONAL {?item wdt:P478 ?volume} .
OPTIONAL {?item wdt:P433 ?issue} .
OPTIONAL {?item wdt:P304 ?pages0} .
OPTIONAL {?item wdt:P1476 ?title} .
BIND(REPLACE(?pages0, "-", "–") AS ?pages)
BIND(strbefore(?pages, "–") as ?startpage)
BIND(strafter(?pages, "–") as ?endpage)
}
ORDER BY ASC(?doi)
Rules
editNaming
editViolation of Rule 8 (Names of Taxa above the Rank of Order)
edit= class (Q37517) =
editSELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q37517 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "ia")))
}
ORDER BY ASC(?taxonName)
SELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q5867051 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "idae")))
}
ORDER BY ASC(?taxonName)
Violation of Rule 9 (Names of Taxa between Subclass and Genus)
edit= order (Q36602) =
editSELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q36602 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "ales")))
}
ORDER BY ASC(?taxonName)
SELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q5867959 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "ineae")))
}
ORDER BY ASC(?taxonName)
= family (Q35409) =
editSELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q35409 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "aceae")))
}
ORDER BY ASC(?taxonName)
SELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q2455704 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "oideae")))
}
ORDER BY ASC(?taxonName)
= tribe (Q227936) =
editSELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q227936 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "eae"))) # TODO
}
ORDER BY ASC(?taxonName)
SELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q3965313 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!(STRENDS(?taxonName, "inae"))) # TODO
}
ORDER BY ASC(?taxonName)
Violation of Rule 13a (Names of Subspecies)
editSELECT DISTINCT ?item ?taxonName WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 wd:Q68947 .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
Filter(!REGEX(?taxonName, " subsp. "))
}
ORDER BY ASC(?taxonName)
Nomenclatural Types
editTODO: Two Codes Cyanophyceae (Q18575364) vs. Cyanobacteria (Q93315) (see Taxonomy of cyanobacteria: a contribution to consensus approach (Q59395002))
Violation of Rule 18a (Type of a Species or Subspecies)
edit# in special cases the place of the type strain may be taken Species by a description, preserved specimen, or an illustration (see Rule 18a(1))
SELECT DISTINCT ?item ?taxonName ?nomenclaturalType ?rankOfNomenclaturalTypeLabel ?lpsnUrl WHERE {
VALUES ?taxonRank {wd:Q7432 wd:Q68947} .
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
OPTIONAL {?item wdt:P427/wdt:P225 ?nomenclaturalType} .
OPTIONAL {?item wdt:P427/wdt:P105 ?rankOfnomenclaturalType} .
OPTIONAL {?item wdt:P1991 ?lpsnUrl} .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!bound(?nomenclaturalType)|| !sameTerm(?rankOfNomenclaturalType, wd:Q855769))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?taxonName)
Violation of Rule 20a (Type of a Genus)
editSELECT DISTINCT ?item ?taxonName ?nomenclaturalType ?rankOfNomenclaturalTypeLabel ?lpsnUrl WHERE {
VALUES ?taxonRank {wd:Q34740 wd:Q3238261} .
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
OPTIONAL {?item wdt:P427/wdt:P225 ?nomenclaturalType} .
OPTIONAL {?item wdt:P427/wdt:P105 ?rankOfnomenclaturalType} .
OPTIONAL {?item wdt:P1991 ?lpsnUrl} .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!bound(?nomenclaturalType)|| !sameTerm(?rankOfNomenclaturalType, wd:Q7432))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?taxonName)
Violation of Rule 20g (Type of a Subgenus)
editTODO
Violation of Rule 21a (Type of a Taxon from Genus to Order (Subtribe, Tribe, Subfamily, Family, Suborder, and Order))
editSELECT DISTINCT ?item ?taxonName ?taxonRankLabel ?nomenclaturalType ?rankOfNomenclaturalTypeLabel ?lpsnUrl WHERE {
VALUES ?taxonRank {wd:Q3965313 wd:Q227936 wd:Q2455704 wd:Q35409 wd:Q5867959 wd:Q36602} .
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
OPTIONAL {?item wdt:P427/wdt:P225 ?nomenclaturalType} .
OPTIONAL {?item wdt:P427/wdt:P105 ?rankOfnomenclaturalType} .
OPTIONAL {?item wdt:P1991 ?lpsnUrl} .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!bound(?nomenclaturalType)|| !sameTerm(?rankOfNomenclaturalType, wd:Q34740))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?taxonRankLabel) ASC(?taxonName)
Violation of Rule 22 (Type of a Taxon Higher than Order)
editSELECT DISTINCT ?item ?taxonName ?taxonRankLabel ?nomenclaturalType ?rankOfNomenclaturalTypeLabel ?lpsnUrl WHERE {
VALUES ?taxonRank {wd:Q5867051 wd:Q37517} .
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
OPTIONAL {?item wdt:P427/wdt:P225 ?nomenclaturalType} .
OPTIONAL {?item wdt:P427/wdt:P105 ?rankOfnomenclaturalType} .
OPTIONAL {?item wdt:P1991 ?lpsnUrl} .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q743780 .
FILTER(!bound(?nomenclaturalType)|| !sameTerm(?rankOfNomenclaturalType, wd:Q36602))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?taxonRankLabel) ASC(?taxonName)
Taxa
editSELECT DISTINCT ?item ?taxonName ?taxonRankLabel WHERE {
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q14920640.
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?taxonName)
Ranks
editSELECT DISTINCT ?taxonRankLabel (COUNT(?taxonRankLabel) AS ?countOfTaxonRank) WHERE {
?item wdt:P105 ?taxonRank .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q14920640.
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
GROUP BY ?taxonRankLabel
ORDER BY DESC(?countOfTaxonRank)
Type species
editSELECT DISTINCT ?item ?taxonName ?nomenclaturalType ?rankOfNomenclaturalTypeLabel WHERE {
VALUES ?taxonRank {wd:Q34740} .
?item wdt:P225 ?taxonName .
?item wdt:P105 ?taxonRank .
OPTIONAL {?item wdt:P427/wdt:P225 ?nomenclaturalType} .
OPTIONAL {?item wdt:P427/wdt:P105 ?rankOfnomenclaturalType} .
?item (wdt:P171)* ?higherParent .
?higherParent wdt:P944 wd:Q14920640 .
#FILTER(!bound(?nomenclaturalType)|| !sameTerm(?rankOfNomenclaturalType, wd:Q855769))
#FILTER(bound(?nomenclaturalType))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
ORDER BY ASC(?taxonName)
ICTV Master Species Lists
editSELECT DISTINCT ?item ?title ?published WHERE {
?item wdt:P629 wd:Q45362532 . #ICTV Master Species List
?item wdt:P1476 ?title .
?item wdt:P577 ?published .
}
ORDER BY ASC(?published)
Maintenance
editFormat
editSELECT ?item ?taxonName WHERE {
SERVICE gas:service {
gas:program gas:gasClass "com.bigdata.rdf.graph.analytics.BFS" .
gas:program gas:in wd:Q756 . # Plantae
gas:program gas:out ?item .
gas:program gas:maxIterations 20 .
gas:program gas:maxVisited 2700000 .
gas:program gas:linkType wdt:P171 .
gas:program gas:traversalDirection "Reverse" .
}
?item wdt:P105 wd:Q7432 .
?item wdt:P225 ?taxonName .
FILTER (CONTAINS(?taxonName, "'"))
}
ORDER BY ASC(?taxonName)
SELECT ?item ?taxonName WHERE {
?item wdt:P105 wd:Q4886 . # Cultivar
?item wdt:P225 ?taxonName .
FILTER (CONTAINS(?taxonName, "'"))
}
ORDER BY ASC(?taxonName)
Rank or cultivarname
editSELECT DISTINCT ?item ?taxonName ?taxonRankLabel WHERE {
{
?item wdt:P31 wd:Q4886 .
OPTIONAL {?item wdt:P225 ?taxonName}
}
UNION {
VALUES ?ranks {wd:Q4886 wd:Q4150646} . # cultivar, cultivar-group
?item wdt:P105 ?ranks.
?item wdt:P225 ?taxonName .
}
OPTIONAL {?item wdt:P105 ?taxonRank}
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
#FILTER(!sameTerm(?taxonRank, wd:Q4886) && !sameTerm(?taxonRank, wd:Q4150646))
FILTER(!BOUND(?taxonName))
}
ORDER BY ASC(?taxonName)
Databases
editStatistic
editSELECT ?countOfIpniPublicationId ?countOfIpniAuthorId ?countOfIpniTaxonId
WITH {
SELECT (COUNT(*) AS ?countOfIpniPublicationId) WHERE {
[] wdt:P2008 [].
}
} AS %countOfIpniPublicationId
WITH {
SELECT (COUNT(*) AS ?countOfIpniAuthorId) WHERE {
[] wdt:P586 [].
}
} AS %countOfIpniAuthorId
WITH {
SELECT (COUNT(*) AS ?countOfIpniTaxonId) WHERE {
[] wdt:P961 [].
}
} AS %countOfIpniTaxonId
WHERE {
INCLUDE %countOfIpniPublicationId.
INCLUDE %countOfIpniAuthorId.
INCLUDE %countOfIpniTaxonId.
}
Statistic
editSELECT ?countOfWoRMSPublicationId ?countOfWoRMSTaxonId
WITH {
SELECT (COUNT(*) AS ?countOfWoRMSPublicationId) WHERE {
[] wdt:P6678 [].
}
} AS %countOfWoRMSPublicationId
WITH {
SELECT (COUNT(*) AS ?countOfWoRMSTaxonId) WHERE {
[] wdt:P850 [].
}
} AS %countOfWoRMSTaxonId
WHERE {
INCLUDE %countOfWoRMSPublicationId.
INCLUDE %countOfWoRMSTaxonId.
}
Statistic
editSELECT ?countOfTropicosPublicationId ?countOfTropicosTaxonId
WITH {
SELECT (COUNT(*) AS ?countOfTropicosPublicationId) WHERE {
[] wdt:P4904 [].
}
} AS %countOfTropicosPublicationId
WITH {
SELECT (COUNT(*) AS ?countOfTropicosTaxonId) WHERE {
[] wdt:P960 [].
}
} AS %countOfTropicosTaxonId
WHERE {
INCLUDE %countOfTropicosPublicationId.
INCLUDE %countOfTropicosTaxonId.
}
Statistic
editSELECT ?countOfZoobankPublicationId ?countOfZoobankAuthorId ?countOfZoobankActId
WITH {
SELECT (COUNT(*) AS ?countOfZoobankPublicationId) WHERE {
[] wdt:P2007 [].
}
} AS %countOfZoobankPublicationId
WITH {
SELECT (COUNT(*) AS ?countOfZoobankAuthorId) WHERE {
[] wdt:P2006 [].
}
} AS %countOfZoobankAuthorId
WITH {
SELECT (COUNT(*) AS ?countOfZoobankActId) WHERE {
[] wdt:P1746 [].
}
} AS %countOfZoobankActId
WHERE {
INCLUDE %countOfZoobankPublicationId.
INCLUDE %countOfZoobankAuthorId.
INCLUDE %countOfZoobankActId.
}
Misc
editStatistic
editSELECT ?iucnStatusLabelDe (COUNT(?iucnStatusLabelDe) AS ?countOfIucnStatus) WHERE {
?item wdt:P141 ?iucnStatus .
SERVICE wikibase:label {
bd:serviceParam wikibase:language "de" .
?iucnStatus rdfs:label ?iucnStatusLabelDe .
}
}
GROUP BY ?iucnStatusLabelDe
ORDER BY ASC(?countOfIucnStatus)
Referenced by previous list
editSELECT ?item ?taxonName ?iucnStatusLabelDe ?iucnStatusLabelEn ?iucnId WHERE {
?item wdt:P141 ?iucnStatus .
?item wdt:P225 ?taxonName .
?item p:P141 ?iucnStatus1 .
?iucnStatus1 ps:P141 ?iucnStatusValue .
?iucnStatus1 prov:wasDerivedFrom ?ref .
?ref pr:P248 wd:Q56011232. # previous list 2018/1
SERVICE wikibase:label {
bd:serviceParam wikibase:language "de" .
?iucnStatus rdfs:label ?iucnStatusLabelDe .
}
SERVICE wikibase:label {
bd:serviceParam wikibase:language "en" .
?iucnStatus rdfs:label ?iucnStatusLabelEn .
}
}
ORDER BY ASC(?iucnStatusLabelDe)
Possibly wrong Id
editSELECT ?item ?taxonName ?iucnId ?iucnIdInRef WHERE {
?item wdt:P627 ?iucnId .
?item wdt:P225 ?taxonName .
?item p:P141 ?iucnStatus .
?iucnStatus ps:P141 ?iucnStatusValue .
?iucnStatus prov:wasDerivedFrom ?ref .
OPTIONAL {?ref pr:P627 ?iucnIdInRef} .
FILTER (?iucnId != ?iucnIdInRef)
}
ORDER BY ASC(xsd:integer(?iucnId))
SELECT ?item ?taxonName ?birdLifeId ?iucnId WHERE {
?item wdt:P5257 ?birdLifeId .
?item wdt:P225 ?taxonName .
OPTIONAL {?item wdt:P627 ?iucnId }
FILTER (?birdLifeId != ?iucnId)
#FILTER (!BOUND(?iucnId))
}
Maintenance
editExternal ID vs. reference URL (P854)
editSELECT ?item ?id ?taxonName ?urlAsSource ?importedFromWikimediaProject ?statedIn WHERE {
?item wdt:P225 ?taxonName .
?item p:P685/ps:P685 ?id .
?item p:P685 ?idStatement .
?idStatement prov:wasDerivedFrom ?ref .
OPTIONAL {?ref pr:P854 ?urlAsSource} .
OPTIONAL {?ref pr:P143 ?importedFromWikimediaProject} .
OPTIONAL {?ref pr:P248 ?statedIn} .
BIND(str(?urlAsSource) as ?urlAsSourceString)
FILTER(!bound(?statedIn))
FILTER(strStarts(?urlAsSourceString, "https://www.ncbi.nlm.nih.gov/"))
#FILTER(bound(?statedIn) && !sameTerm(?statedIn, wd:Q13711410))
}
ORDER BY ASC(xsd:integer(?id)) ASC(?taxonName)