query-a0e3c3afdd76c17387b118705b5e9bea

rq turtle/ttl

TODO

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT distinct ?item ?itemLabel ?langLabel ?ext
where {
   { ?item wdt:P31 wd:Q235557.         # Instance of file format
    ?item wdt:P277 ?lang. }            # must be a programming language
  UNION                                # and/or
   { ?item wdt:P31/wdt:P279* wd:Q9143 .       # Instance of programming language
     ?item rdfs:label ?langLabel.      # and get its Label 
     filter(lang(?langLabel)="en")}    # in English 
  ?item wdt:P1195 ?ext                 # must have a file extension
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" } # get Labels
} order by ?langLabel ?ext

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v2("?ext"):::projected v3("?item"):::projected v4("?lang") v1("?langLabel"):::projected a1((" ")) c2(["wd:Q235557"]):::iri c10(["bd:serviceParam"]):::iri c6(["wd:Q9143"]):::iri c12(["#91;AUTO_LANGUAGE#93;,en"]):::literal subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; f0[["?langLabel = 'en'"]] f0 --> v1 v3 --"wdt:P31"--> a1 a1 --"wdt:P279"--> c6 v3 --"rdfs:label"--> v1 end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; v3 --"wdt:P31"--> c2 v3 --"wdt:P277"--> v4 end union0r <== or ==> union0l end v3 --"wdt:P1195"--> v2 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c10 --"wikibase:language"--> c12 end