query-097b626650b9c8223b6a4a7746c912d1

rq turtle/ttl

However, we need to get the title of the Wikipedia pages so that Massviews, the tool that we are going to use later, is able to retrieve the page views of those pages. The following query retrieves the title of the Wikipedia pages of the previously obtained items.

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
SELECT ?title {
  ?item wdt:P106 wd:Q36180;
        wdt:P27 wd:Q419;
        wdt:P21 wd:Q6581072.

  ?article schema:about ?item;
           schema:isPartOf <https://es.wikipedia.org/>.

  BIND(wikibase:decodeUri(SUBSTR(STR(?article), 31)) AS ?title).
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v2("?article") v1("?item") v3("?title"):::projected c9([https://es.wikipedia.org/]):::iri c4(["wd:Q419"]):::iri c6(["wd:Q6581072"]):::iri c2(["wd:Q36180"]):::iri v1 --"wdt:P106"--> c2 v1 --"wdt:P27"--> c4 v1 --"wdt:P21"--> c6 v2 --"schema:about"--> v1 v2 --"schema:isPartOf"--> c9 bind0[/"http://wikiba.se/ontology#decodeUri(substring(str(?article),'31^^xsd:integer'))"/] v2 --o bind0 bind0 --as--o v3