query-80aab0359f13deaf824103a1407fd908
Japanese family names but not the same kana/Hepburn/kanji
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?name1 ?name2 ?name1Label ?name2Label ?orig ?hepburn1 ?hepburn2
WHERE {
?name1 wdt:P31/wdt:P279* wd:Q101352 ;
p:P1814 ?kana1 ;
wdt:P1705 ?count .
?kana1 ps:P1814 ?orig ;
pq:P2125 ?hepburn1 .
?name2 wdt:P31/wdt:P279* wd:Q101352 ;
p:P1814 ?kana2 ;
wdt:P1705 ?count2 .
?kana2 ps:P1814 ?orig ;
pq:P2125 ?hepburn2 .
FILTER (?name1 != ?name2)
FILTER (?hepburn1 != ?hepburn2)
SERVICE wikibase:label { bd:serviceParam wikibase:language "en" . }
}GROUP BY ?name1 ?name2 ?name1Label ?name2Label ?orig ?hepburn1 ?hepburn2
HAVING((COUNT(?count) = 1) && (COUNT(?count2) = 1))
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v10("?_anon_42b5416610844a34809f33a099ae9de1104325")
v11("?_anon_42b5416610844a34809f33a099ae9de1104326")
v6("?count")
v9("?count2")
v1("?hepburn1"):::projected
v2("?hepburn2"):::projected
v5("?kana1")
v8("?kana2")
v3("?name1"):::projected
v4("?name2"):::projected
v7("?orig"):::projected
a3((" "))
a4((" "))
a1((" "))
a2((" "))
c4(["wd:Q101352"]):::iri
c10(["bd:serviceParam"]):::iri
c12(["en"]):::literal
f0[[" = '1^^xsd:integer' = '1^^xsd:integer'"]]
f0 --> a1
f0 --> a2
f1[["?hepburn1 != ?hepburn2"]]
f1 --> v1
f1 --> v2
f2[["?name1 != ?name2"]]
f2 --> v3
f2 --> v4
v3 --"p:direct/P31"--> a3
a3 --"p:direct/P279"--> c4
v3 --"p:P1814"--> v5
v3 --"p:direct/P1705"--> v6
v5 --"p:statement/P1814"--> v7
v5 --"p:qualifier/P2125"--> v1
v4 --"p:direct/P31"--> a4
a4 --"p:direct/P279"--> c4
v4 --"p:P1814"--> v8
v4 --"p:direct/P1705"--> v9
v8 --"p:statement/P1814"--> v7
v8 --"p:qualifier/P2125"--> v2
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c10 --"wikibase:language"--> c12
end
bind5[/"count(?count)"/]
v6 --o bind5
bind5 --as--o v10
bind6[/"count(?count2)"/]
v9 --o bind6
bind6 --as--o v11