query-65b27ad3a7ac0058c96e56b4dad1766b

rq turtle/ttl

b. # assertions

Tbd: include sitelinks?

SELECT (SUM(?st) as ?nb_assertions) WITH { SELECT DISTINCT ?item ?st WHERE { ?item wdt:P279* wd:Q181388 . # ?item wdt:P641 wd:Q847 . ?item wikibase:statements ?st . }
} as %a { INCLUDE %a }

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
#  b. # assertions
# Tbd: include sitelinks?
SELECT (SUM(?st) as ?nb_assertions) 
{

{
    SELECT DISTINCT ?item ?st 
    WHERE
    {
        ?item wdt:P279* wd:Q181388 .
        # ?item wdt:P641 wd:Q847 .
        ?item wikibase:statements ?st . 
    }      
}
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v1("?item") v3("?nb_assertions") v2("?st"):::projected c2(["wd:Q181388"]):::iri v1 --"wdt:P279"--> c2 v1 --"wikibase:statements"--> v2 bind1[/"sum(?st)"/] v2 --o bind1 bind1 --as--o v3