query-5eebe120898e3bff8b9c9f8f4d588992
Propertiesinstance of (P31)sex or gender (P21)place of birth (P19)located in the administrative territorial entity (P131)native language (P103)languages spoken, written or signed (P1412)date of birth (P569)date of death (P570)place of death (P20)
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 bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?statements ?linkcount ?itemLabel ?birth ?pobLabel ?death ?podLabel
WHERE {
?item wdt:P31 wd:Q5 . # item = humans only
?item wdt:P21 wd:Q6581072 . # gender = female only
{ ?item wdt:P19 wd:Q22048 } # place of birth = Odisha (Q22048)
UNION { ?item wdt:P19 ?pob . ?pob wdt:P131* wd:Q22048 } # OR place of birth within Odisha.
UNION {?item wdt:P103 wd:Q33810 } # native language = Odia
UNION {?item wdt:P1412 wd:Q33810 } # OR language spoken/ written/ signed = Odia
OPTIONAL { ?item wdt:P569 ?birth }
OPTIONAL { ?item wdt:P19 ?pob }
OPTIONAL { ?item wdt:P570 ?death }
OPTIONAL { ?item wdt:P20 ?pod }
OPTIONAL { ?item wikibase:sitelinks ?linkcount. } #count sitelinks
?item wikibase:statements ?statements . # for counting statements
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" } # for generating label
}
GROUP BY ?item ?statements ?linkcount ?itemLabel ?birth ?pobLabel ?death ?podLabel
ORDER BY DESC(?linkcount)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v4("?birth"):::projected
v5("?death"):::projected
v2("?item"):::projected
v1("?linkcount"):::projected
v3("?pob")
v6("?pod")
v7("?statements"):::projected
c4(["wd:Q6581072"]):::iri
c6(["wd:Q22048"]):::iri
c17(["bd:serviceParam"]):::iri
c2(["wd:Q5"]):::iri
c19(["#91;AUTO_LANGUAGE#93;,en"]):::literal
c9(["wd:Q33810"]):::iri
v2 --"wdt:P31"--> c2
v2 --"wdt:P21"--> c4
subgraph union0[" Union "]
subgraph union0l[" "]
style union0l fill:#abf,stroke-dasharray: 3 3;
subgraph union1[" Union "]
subgraph union1l[" "]
style union1l fill:#abf,stroke-dasharray: 3 3;
subgraph union2[" Union "]
subgraph union2l[" "]
style union2l fill:#abf,stroke-dasharray: 3 3;
v2 --"wdt:P1412"--> c9
end
subgraph union2r[" "]
style union2r fill:#abf,stroke-dasharray: 3 3;
v2 --"wdt:P103"--> c9
end
union2r <== or ==> union2l
end
end
subgraph union1r[" "]
style union1r fill:#abf,stroke-dasharray: 3 3;
v2 --"wdt:P19"--> v3
v3 --"wdt:P131"--> c6
end
union1r <== or ==> union1l
end
end
subgraph union0r[" "]
style union0r fill:#abf,stroke-dasharray: 3 3;
v2 --"wdt:P19"--> c6
end
union0r <== or ==> union0l
end
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P569".-> v4
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P19".-> v3
end
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P570".-> v5
end
subgraph optional3["(optional)"]
style optional3 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P20".-> v6
end
subgraph optional4["(optional)"]
style optional4 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wikibase:sitelinks".-> v1
end
v2 --"wikibase:statements"--> v7
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c17 --"wikibase:language"--> c19
end