User:Netha Hussain/Query list
Cats
- List of notable cats
The following query uses these:
- Items: house cat (Q146)
- Properties: instance of (P31)
SELECT ?item ?itemLabel WHERE { ?item wdt:P31 wd:Q146. SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } }
Women born in in Gothenburg
- List of women born in Gothenburg
The following query uses these:
- Items: human (Q5) , Gothenburg (Q25287) , female (Q6581072)
- Properties: instance of (P31) , place of birth (P19) , sex or gender (P21)
SELECT ?item ?itemLabel WHERE { ?item wdt:P31 wd:Q5. SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?item wdt:P19 wd:Q25287. ?item wdt:P21 wd:Q6581072. }
Proportion of biographies by gender
- Distribution of biography articles by gender on Malayalam Wikipedia:
The following query uses these:
- Items: human (Q5)
- Properties: instance of (P31) , sex or gender (P21)
SELECT (count(?gender) as ?count) ?genderLabel WHERE { ?item wdt:P31 wd:Q5. # all humans ?item wdt:P21 ?gender. # who have some gender property ?article schema:about ?item. # and have an article about them ?article schema:isPartOf <https://ml.wikipedia.org/> . # on *Malayalam* Wikipedia SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } } GROUP BY ?genderLabel ORDER BY DESC(?count)
Images of poisonous mushrooms
- Images of poisonous mushrooms
The following query uses these:
- Properties: edibility (P789) , image (P18)
SELECT ?item ?itemLabel ?pic WHERE { ?item wdt:P789 wd:Q19888562. OPTIONAL { ?item wdt:P18 ?pic. } SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } }
Wikimedia list articles without ml descriptions
- List of 500 articles that contain lists and do not have ml descriptions
The following query uses these:
- Properties: instance of (P31)
SELECT DISTINCT ?item WHERE { ?item wdt:P31 wd:Q13406463. OPTIONAL { ?item schema:description ?itemDescription. } SERVICE wikibase:label { bd:serviceParam wikibase:language "ml". } FILTER(!BOUND(?itemDescription)) } LIMIT 500
Indian women scientists by subspeciality
- List of scientists of Indian citizenship
The following query uses these:
- Items: India (Q668) , female (Q6581072) , scientist (Q901)
- Properties: country of citizenship (P27) , sex or gender (P21) , occupation (P106) , subclass of (P279)
SELECT ?itemLabel ?sub0Label WHERE { ?item wdt:P27 wd:Q668. SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?item wdt:P21 wd:Q6581072. ?item wdt:P106 ?sub0. ?sub0 wdt:P279* wd:Q901. }
Malayalam actors
- List of actors who speak, write or sign in Malayalam
- Use: WDFIST and missing labels in Malayalam
The following query uses these:
- Items: actor (Q33999) , Malayalam (Q36236)
- Properties: occupation (P106) , languages spoken, written or signed (P1412)
SELECT ?Kozhikode ?KozhikodeLabel WHERE { SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?Kozhikode wdt:P106 wd:Q33999. ?Kozhikode wdt:P1412 wd:Q36236. }
Diseases
- List of diseases
Use : WDFIST image recognition
The following query uses these:
- Items: disease (Q12136)
- Properties: instance of (P31)
SELECT ?disease ?diseaseLabel WHERE { SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?disease wdt:P31 wd:Q12136. }
Wikimedia list articles
- List of Wikimedia list articles
- Use : Quick statements, to add ml labels
The following query uses these:
- Properties: instance of (P31)
SELECT ?item WHERE { ?item wdt:P31 wd:Q13406463. SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } }
List of all scientists
The following query uses these:
- Items: human (Q5) , scientist (Q901)
- Properties: instance of (P31) , occupation (P106) , subclass of (P279)
SELECT ?human ?humanLabel WHERE { SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?human wdt:P31 wd:Q5. ?human wdt:P106 ?occupation. ?occupation wdt:P279* wd:Q901. } LIMIT 100
Scientists born after 1900
The following query uses these:
- Items: human (Q5) , scientist (Q901)
- Properties: instance of (P31) , occupation (P106) , subclass of (P279) , date of birth (P569) , date of death (P570)
SELECT ?human ?humanLabel ?date_of_birth ?date_of_death WHERE { SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?human wdt:P31 wd:Q5. ?human wdt:P106 ?occupation. ?occupation wdt:P279* wd:Q901. ?human wdt:P569 ?born. FILTER(?born >= "1900-01-01T00:00:00Z"^^xsd:dateTime) OPTIONAL { ?human wdt:P569 ?date_of_birth. } OPTIONAL { ?human wdt:P570 ?date_of_death. } } LIMIT 100
Scientists born between 1500 and 1700 with age
The following query uses these:
- Items: human (Q5) , scientist (Q901)
- Properties: instance of (P31) , occupation (P106) , subclass of (P279) , date of birth (P569) , date of death (P570) , country of citizenship (P27)
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> SELECT ?human ?humanLabel ?date_of_birth ?date_of_death (ROUND((?date_of_death - ?date_of_birth) / "365.2425"^^xsd:decimal) AS ?age) ?country_of_citizenship ?country_of_citizenshipLabel ?occupation ?occupationLabel WHERE { SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?human wdt:P31 wd:Q5. ?human wdt:P106 ?occupation. ?occupation wdt:P279* wd:Q901. ?human wdt:P569 ?born. OPTIONAL { ?human wdt:P569 ?date_of_birth. } OPTIONAL { ?human wdt:P570 ?date_of_death. } OPTIONAL { ?human wdt:P27 ?country_of_citizenship. } FILTER((?born >= "1500-01-01T00:00:00Z"^^xsd:dateTime) && (?born <= "1700-01-01T00:00:00Z"^^xsd:dateTime)) OPTIONAL { ?human wdt:P106 ?occupation. } } LIMIT 100
Scientists (sub classes included) with images
The following query uses these:
- Items: human (Q5) , scientist (Q901) , India (Q668)
- Properties: instance of (P31) , occupation (P106) , subclass of (P279) , country of citizenship (P27) , image (P18)
SELECT ?human ?humanLabel ?image WHERE { SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?human wdt:P31 wd:Q5; (wdt:P106/(wdt:P279*)) wd:Q901. ?human wdt:P27 wd:Q668. OPTIONAL { ?human wdt:P18 ?image. } } LIMIT 100
Most needed female writers on Malayalam Wikipedia
Note: Change the need level by decreasing the number of sitelinks
The following query uses these:
- Items: human (Q5) , female (Q6581072) , writer (Q36180)
- Properties: instance of (P31) , sex or gender (P21) , occupation (P106)
SELECT ?item ?itemLabel ?linkcount WHERE { ?item wdt:P31 wd:Q5; wdt:P21 wd:Q6581072; wdt:P106 wd:Q36180; wikibase:sitelinks ?linkcount. FILTER(?linkcount >= 50 ) FILTER(NOT EXISTS { ?article schema:about ?item; schema:inLanguage "ml"; schema:isPartOf <https://ml.wikipedia.org/>. }) SERVICE wikibase:label { bd:serviceParam wikibase:language "en,de,es,ar,fr". } } GROUP BY ?item ?itemLabel ?linkcount ORDER BY DESC (?linkcount)
Indian citizens with an article in English but not in Malayalam
The following query uses these:
- Items: human (Q5) , India (Q668)
- Properties: instance of (P31) , country of citizenship (P27)
SELECT ?item ?itemLabel (COUNT(DISTINCT ?sitelink) AS ?count) WHERE { ?item wdt:P31 wd:Q5; wdt:P27 wd:Q668. ?sitelink schema:about ?item. FILTER(EXISTS { ?wen schema:about ?item; schema:inLanguage "en". }) FILTER(NOT EXISTS { ?wfr schema:about ?item; schema:inLanguage "ml". }) SERVICE wikibase:label { bd:serviceParam wikibase:language "fr,en". } } GROUP BY ?item ?itemLabel ORDER BY DESC (?count)
Books in public domain
The following query uses these:
- Items: book (Q571) , public domain (Q19652)
- Properties: instance of (P31) , copyright status (P6216)
SELECT ?website ?websiteLabel WHERE { SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } ?website wdt:P31 wd:Q571. OPTIONAL { } ?website wdt:P6216 wd:Q19652. }
Branches of science with Hindi description
The following query uses these:
- Items: branch of science (Q2465832)
- Properties: instance of (P31)
SELECT ?item ?len ?den ?lhi ?dhi WHERE { ?item wdt:P31 wd:Q2465832. OPTIONAL { ?item rdfs:label ?len. FILTER((LANG(?len)) = "en") } OPTIONAL { ?item rdfs:label ?lhi. FILTER((LANG(?lhi)) = "hi") } OPTIONAL { ?item schema:description ?den. FILTER((LANG(?den)) = "en") } FILTER(NOT EXISTS { ?item schema:description ?dhi. FILTER((LANG(?dhi)) = "hi") })
Number of objects related to African women
The following query uses these:
- Items: human (Q5) , female (Q6581072) , country (Q6256) , Africa (Q15)
- Properties: instance of (P31) , sex or gender (P21) , country of citizenship (P27) , continent (P30)
SELECT ?citizenshipLabel (COUNT(DISTINCT ?item) AS ?ccount) WHERE { ?item wdt:P31 wd:Q5. ?item wdt:P21 wd:Q6581072. ?item wdt:P27 ?citizenship. ?citizenship wdt:P31 wd:Q6256. ?citizenship wdt:P30 wd:Q15. SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } } GROUP BY ?citizenshipLabel ORDER BY DESC(?ccount)
Malayalam words with missing senses
The following query uses these:
- Properties: ISO 639-1 code (P218)
SELECT ?l ?lemma WHERE { ?l a ontolex:LexicalEntry ; dct:language ?language ; wikibase:lemma ?lemma . ?language wdt:P218 'ml' FILTER NOT EXISTS {?l ontolex:sense ?sense } }
Malayalam adverbs with missing pronunciation audio
The following query uses these:
- Items: Malayalam (Q36236) , adverb (Q380057)
- Properties: pronunciation audio (P443)
#title:All adverbs in Malayalam missing a pronunciation SELECT ?id ?label WHERE { ?id dct:language wd:Q36236; wikibase:lexicalCategory wd:Q380057; wikibase:lemma ?label. MINUS { ?id wdt:P443 ?audio. } } LIMIT 300
Map of villages of India
The following query uses these:
- Items: village (Q532) , India (Q668)
- Properties: instance of (P31) , subclass of (P279) , country (P17) , coordinate location (P625)
SELECT ?village ?villageLabel ?coordinates WHERE { ?village wdt:P31/wdt:P279* wd:Q532; # Instance of (or subclass of) a village wdt:P17 wd:Q668; # Located in India wdt:P625 ?coordinates. # Geographical coordinates SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } } LIMIT 5000