query-cc7a12cb6f526df402869d211ea20e5a

rq turtle/ttl

Total de usos d'una propietat, mostrant a més altres propietats de cadascun dels valors totalitzats SELECT ?value ?valueLabel ?ct ?sampleitem ?sampleitemLabel ?propassoc WHERE { { SELECT ?value (count(*) as ?ct) (SAMPLE(?item) as ?sampleitem) WHERE { ?item wdt:P1435 ?value. } GROUP BY ?value ORDER BY DESC(?ct) LIMIT 1000 }

mostrar la P1687 de cadascun dels valors totalitzats

  ?value wdt:P1687 ?propassoc.

SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" } } ORDER BY DESC(?ct) ASC(?value)

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#Total de usos d'una propietat, mostrant a més altres propietats de cadascun dels valors totalitzats
SELECT ?value ?valueLabel ?ct ?sampleitem ?sampleitemLabel ?propassoc
WHERE
{
  {
    SELECT ?value (count(*) as ?ct) (SAMPLE(?item) as ?sampleitem)
    WHERE
    {
      ?item wdt:P1435 ?value.
    }
    GROUP BY ?value
    ORDER BY DESC(?ct)
    LIMIT 1000
  }
#mostrar la P1687 de cadascun dels valors totalitzats
      ?value wdt:P1687 ?propassoc.

  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" }
}
ORDER BY DESC(?ct) ASC(?value)

Query found at

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