query-57516f0e570d3cc6d96498ee9b217dc7
Specific Querys Wikidata:Tools/Wikidata for WebQuery to show list of the most popular family names in Wikidata that do not have a "MyHeritage Surname ID", it includes a link to show them in myhertage so you may connect them in easily back to wikidata using something like TODO
Use at
- https://query.wikidata.org/sparql
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?count ?name ?name_label ?check_url
WHERE {
{
SELECT (COUNT(*) AS ?count) ?name WHERE {
{
SELECT ?item ?name WHERE {
?item wdt:P734 ?name
} LIMIT 1000000
} } GROUP BY ?name
HAVING (?count > 4)
} MINUS {?name wdt:P5452 [] } .
?name rdfs:label ?name_label FILTER(lang(?name_label) = 'en') .
wd:P5452 wdt:P1630 ?fmt .
BIND(IRI(REPLACE(str(?name_label), '(^.*)', ?fmt)) AS ?check_url) .
} ORDER BY DESC(?count)
Query found at
- https://www.wikidata.org/wiki/Property_talk:P5452
- https://www.wikidata.org/wiki/Wikidata:Request_a_query/Archive/2022/02
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v6("?check_url"):::projected
v5("?count"):::projected
v5("?fmt")
v3("?item")
v4("?name"):::projected
v2("?name_label"):::projected
a1((" "))
c6(["wd:P5452"]):::iri
f0[["?name_label = 'en'"]]
f0 --> v2
f1[["?count > '4^^xsd:integer'"]]
f1 --> v5
v3 --"wdt:P734"--> v4
bind3[/"count(*)"/]
bind3 --as--o v5
subgraph minus4["MINUS"]
style minus4 stroke-width:6px,fill:pink,stroke:red;
v4 --"wdt:P5452"--> a1
end
v4 --"rdfs:label"--> v2
c6 --"wdt:P1630"--> v5
bind5[/"replace(str(?name_label),'(^.*)',?fmt)"/]
v2 --o bind5
v5 --o bind5
bind5 --as--o v6