How many {allegiance} are to/by {Empire of Japan} ?
Which is the number of allegiances to the Empire of Japan?
How many allegiance to the Empire of Japan?
SELECT ( COUNT ( ?f ) AS ?r ) { ?f property:allegiance resource:Empire_of_Japan }
SELECT (COUNT(?sub) AS ?subs ) {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> ?sub .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P945> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> http://wikidata.dbpedia.org/resource/Q188712 .
} 

SELECT (COUNT(?sub) AS ?value ) { ?sub wdt:P945 wd:Q188712 }
328