query-678f33c82fea79828eea5aa408db5075

rq turtle/ttl

Output as stringI want an output as plain string. For example "Text Tabulator Text Tabulator Text #Comment ". So that I can create commands for QuickStatments and can easy copy the output as new batch. But when I try I have problems to get and combine the text parts.

Use at

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#>
SELECT distinct ?item ?itemLabel ?itemDescription ?myout2 ?myout3 ?myout4 ?myout5
WHERE {    
  ?item (wdt:P131/wdt:P279*) wd:Q1731 .  # in Dresden 
  ?item (wdt:P31/wdt:P279*) wd:Q41253 .  # is cinema

  #output
  bind(STR(?item) as ?myout1) .
  BIND(REPLACE(?myout1, "http://www.wikidata.org/entity/", "", "i") AS ?myout2) .
  bind(STR(?itemLabel) as ?myout3) .
  bind(STR(?itemDescription) as ?myout4) .
  bind(CONCAT(?myout2, "\t", ?myout3, "\t", ?myout3 ) as ?myout5) .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "de". }
} ORDER BY ?itemLabel

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v2("?item"):::projected v1("?itemLabel"):::projected v3("?myout1") v4("?myout2"):::projected v5("?myout3"):::projected v6("?myout4"):::projected v7("?myout5"):::projected a1((" ")) a2((" ")) c9(["de"]):::literal c7(["bd:serviceParam"]):::iri c5(["wd:Q41253"]):::iri c3(["wd:Q1731"]):::iri v2 --"wdt:P131"--> a1 a1 --"wdt:P279"--> c3 v2 --"wdt:P31"--> a2 a2 --"wdt:P279"--> c5 bind0[/"str(?item)"/] v2 --o bind0 bind0 --as--o v3 bind1[/"replace(?myout1,'http://www.wikidata.org/entity/','','i')"/] v3 --o bind1 bind1 --as--o v4 bind2[/"str(?itemLabel)"/] v1 --o bind2 bind2 --as--o v5 bind3[/"str(?itemDescription)"/] null --o bind3 bind3 --as--o v6 bind4[/"concat(?myout2,' ',?myout3,' ',?myout3)"/] v4 --o bind4 v5 --o bind4 bind4 --as--o v7 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c7 --"wikibase:language"--> c9 end