query-209ef63a62364f121c22845ba1612336

rq turtle/ttl

Items in Wikidata linked to ORKG

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT 
  ?items
  ?class ?classLabel
  ?example_item ?example_itemLabel
WHERE {
   {
  SELECT
    (COUNT(?item) AS ?items)
    ?class
    (SAMPLE(?item) AS ?example_item)
  WHERE {
    ?item wdt:P10897 [] ;
          wdt:P31 ?class . 
  }
  GROUP BY ?class
}  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY DESC(?items)

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v3("?class"):::projected v4("?example_item"):::projected v2("?item") v4("?items"):::projected a1((" ")) c4(["bd:serviceParam"]):::iri c6(["#91;AUTO_LANGUAGE#93;,en"]):::literal v2 --"wdt:P10897"--> a1 v2 --"wdt:P31"--> v3 bind2[/"count(?item)"/] v2 --o bind2 bind2 --as--o v4 bind3[/"sample(?item)"/] v2 --o bind3 bind3 --as--o v4 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c4 --"wikibase:language"--> c6 end