query-3306e14478d21652f06cbe69ea967a68
title: Toutes les langues avec un code de langue Wikimedia (P424)
Date: 2021-09-24
SELECT DISTINCT ?lang_code ?itemLabel ?item WHERE { # ?lang is one of these options VALUES ?lang { wd:Q34770 # language wd:Q436240 # ancient language wd:Q1288568 # modern language wd:Q33215 # constructed language } ?item wdt:P31 ?lang ; # get the language code wdt:P424 ?lang_code . SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],mul,en". } } ORDER BY ?lang_code
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#title: Toutes les langues avec un code de langue Wikimedia (P424)
# Date: 2021-09-24
SELECT DISTINCT ?lang_code ?itemLabel ?item
WHERE
{
# ?lang is one of these options
VALUES ?lang {
wd:Q34770 # language
wd:Q436240 # ancient language
wd:Q1288568 # modern language
wd:Q33215 # constructed language
}
?item wdt:P31 ?lang ;
# get the language code
wdt:P424 ?lang_code .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],mul,en". }
} ORDER BY ?lang_code
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?item"):::projected
v2("?lang")
v1("?lang_code"):::projected
c4(["bd:serviceParam"]):::iri
c6(["#91;AUTO_LANGUAGE#93;,mul,en"]):::literal
bind0[/VALUES ?lang/]
bind0-->v2
bind00(["wd:Q34770"])
bind00 --> bind0
bind01(["wd:Q436240"])
bind01 --> bind0
bind02(["wd:Q1288568"])
bind02 --> bind0
bind03(["wd:Q33215"])
bind03 --> bind0
v3 --"wdt:P31"--> v2
v3 --"wdt:P424"--> v1
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c4 --"wikibase:language"--> c6
end