query-9075f5f6101a8f64c0ab77dcc98616ec
Need for a simple count that is time-consuming https://github.com/OSMBrasil/semantic-bridgeGenerating "time out" error. I need this counting query to } . Q155:wd P17:wdt/)P279:wdt|P31:wdt( ?item .:b0 P402:wdt ?item { WHERE )?count AS )?item DISTINCT(COUNT( SELECT 21:14, 2 August 2018 (UTC)) talk (Krauss--. I try with "similar but not the same" operations, ≥ 5580PS: expected # wdt:P279/wdt:P31/wdt:P17 = 100981 # wdt:P31/wdt:P279/wdt:P17 = 101035 #seems optimal # wdt:P31/wdt:P17 = 100856 # wdt:P17 = 99224 } Q155:wd P17:wdt/P31:wdt/P279:wdt ?item { WHERE )?count AS )?item DISTINCT(COUNT( SELECT # ... seems all = 5580 # wdt:P279/wdt:P31/wdt:P17 = 5580 # wdt:P31/wdt:P279/wdt:P17 = 5580 # wdt:P31/wdt:P17 = 5580 #seems optimal # wdt:P17 = 5579 } Q155:wd P17:wdt*/P31:wdt ?item . :b0 P402:wdt ?item { WHERE )?count AS )?item DISTINCT(COUNT( SELECTI'm not sure what you are trying to count. In general, P17=Q155 should be present on all relevant items. So doing the below should be sufficient (currently 5581):
Use at
- https://query.wikidata.org/sparql
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT (COUNT(DISTINCT ?item) AS ?count)
WHERE
{
?item wdt:P402 _:b0.
?item wdt:P17 wd:Q155 .
}