query-ecd5bc08e8cf27d857dcfb449d0d3404

rq turtle/ttl

Schools in Alappuzha DistrictUsed to fill the gaps in labels

Use at

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#>
SELECT ?item ?ilml ?ilen ?kscode ?udisecode WHERE {
  { ?item wdt:P31 wd:Q9826. }
  UNION
  { ?item wdt:P31 wd:Q64063386. }
  UNION
  { ?item wdt:P31 wd:Q64063317. }
  UNION
  { ?item wdt:P31 wd:Q64062731. }
  ?item (wdt:P131*) wd:Q928959.
  OPTIONAL {
    ?item rdfs:label ?ilml.
    FILTER((LANG(?ilml)) = "ml")
  }
  OPTIONAL {
    ?item rdfs:label ?ilen
    FILTER((LANG(?ilen)) = "en")
  }
  ?item wdt:P7065 ?kscode.
  ?item wdt:P6391 ?udisecode.
  OPTIONAL {  }
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v1("?ilen"):::projected v2("?ilml"):::projected v3("?item"):::projected v4("?kscode"):::projected v5("?udisecode"):::projected c5(["wd:Q64063386"]):::iri c7(["wd:Q64062731"]):::iri c9(["wd:Q928959"]):::iri c4(["wd:Q9826"]):::iri c6(["wd:Q64063317"]):::iri subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; subgraph union1[" Union "] subgraph union1l[" "] style union1l fill:#abf,stroke-dasharray: 3 3; subgraph union2[" Union "] subgraph union2l[" "] style union2l fill:#abf,stroke-dasharray: 3 3; v3 --"wdt:P31"--> c7 end subgraph union2r[" "] style union2r fill:#abf,stroke-dasharray: 3 3; v3 --"wdt:P31"--> c6 end union2r <== or ==> union2l end end subgraph union1r[" "] style union1r fill:#abf,stroke-dasharray: 3 3; v3 --"wdt:P31"--> c5 end union1r <== or ==> union1l end end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; v3 --"wdt:P31"--> c4 end union0r <== or ==> union0l end v3 --"wdt:P131"--> c9 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v3 -."rdfs:label".-> v2 end subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v3 -."rdfs:label".-> v1 end v3 --"wdt:P7065"--> v4 v3 --"wdt:P6391"--> v5 subgraph optional2["(optional)"] style optional2 fill:#bbf,stroke-dasharray: 5 5; end