Template:Query labels
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
Partial query that generates the boilerplate code for showing language-specific labels in SPARQL queries. Inserts the "en" language by default as a parameter to the service, but several parameters can also be given.
Usage
edit{{Query labels}}
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
{{sparql|query= select ?item ?itemLabel { ?item wikibase:sitelinks ?sl filter (?sl>0) . #items with at least one sitelink ?item wdt:{{Pid|influenced by}}* wd:Q15777 . #influence by the C programming language {{Query labels}} } }}
select ?item ?itemLabel {
?item wikibase:sitelinks ?sl filter (?sl>0) . #items with at least one sitelink
?item wdt:P737* wd:Q15777 . #influence by the C programming language
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
}
See also
editPartial query to insert a call to the query service. Language are autofilled but parameters can be done to change the default.
Parameter | Description | Type | Status | |
---|---|---|---|---|
first language | 1 | no description | Unknown | optional |
second language | 2 | no description | Unknown | optional |
third language | 3 | no description | Unknown | optional |
fourth language | 4 | no description | Unknown | optional |
fifth language | 5 | no description | Unknown | optional |
seventh language | 6 | no description | Unknown | optional |
The above documentation is transcluded from Template:Query labels/doc (edit | history). Editors can experiment in this template's sandbox (create | mirror) and testcases (create) page. Please add categories to the /doc subpage. Subpages of this template. |