query-7c1e6dfcff9d81ef1a2978cf4e5abc32

rq turtle/ttl

all objects with a YLE-ID P8309 defined SELECT ?item ?itemLabel ?yleid ?link_fi ?link_sv WHERE { ?item wdt:P8309 ?yleid. BIND (URI(CONCAT("https://yle.fi/aihe/t/", ?yleid)) AS ?link_fi) BIND (URI(CONCAT("https://svenska.yle.fi/t/", ?yleid)) AS ?link_sv) SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],sv,fi,en". } }

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX bd: <http://www.bigdata.com/rdf#>
# all objects with a YLE-ID P8309 defined
SELECT ?item ?itemLabel ?yleid ?link_fi ?link_sv
WHERE
{
  ?item wdt:P8309 ?yleid.
  BIND (URI(CONCAT("https://yle.fi/aihe/t/", ?yleid)) AS ?link_fi)
  BIND (URI(CONCAT("https://svenska.yle.fi/t/", ?yleid)) AS ?link_sv)
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],sv,fi,en". }
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v1("?item"):::projected v3("?link_fi"):::projected v4("?link_sv"):::projected v2("?yleid"):::projected c3(["bd:serviceParam"]):::iri c5(["#91;AUTO_LANGUAGE#93;,sv,fi,en"]):::literal v1 --"wdt:P8309"--> v2 bind0[/"concat('https://yle.fi/aihe/t/',?yleid)"/] v2 --o bind0 bind0 --as--o v3 bind1[/"concat('https://svenska.yle.fi/t/',?yleid)"/] v2 --o bind1 bind1 --as--o v4 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c3 --"wikibase:language"--> c5 end