query-c30fb9ccedfcbb06cf4248dc54c0f564

rq turtle/ttl

Padma awardees (using UNION), 3759 items @26JAN2022 SELECT ?item ?linkcount ?itemLabel ?itemDescription ?awardvalLabel ?year WHERE { ?item wdt:P31 wd:Q5. # <<<<<< Item = Human ?item p:P166 ?award. ?award ps:P166 ?awardval.

{ ?award ps:P166 wd:Q672392. } # <<<<<< Award = Padma Vibhushan UNION { ?award ps:P166 wd:Q84042880.} # <<<<<< Padma Vibhushan_Public Affairs UNION { ?award ps:P166 wd:Q30143915 } # <<<<<< Padma Vibhushan_Literature UNION { ?award ps:P166 wd:Q30147268 } # <<<<<< Padma Vibhushan_Science and Engineering UNION { ?award ps:P166 wd:Q30147343} # <<<<<< Padma Vibhushan_Trade and Industry

UNION { ?award ps:P166 wd:Q932650. } # <<<<<< Award = Padma Bhushan UNION { ?award ps:P166 wd:Q30197118} # <<<<<< Padma Bhushan in Sc. & Eng. UNION { ?award ps:P166 wd:Q63877754} # <<<<<< Award = Padma Bhushan in Lit. & Education UNION { ?award ps:P166 wd:Q110686881} # <<<<<< Award = Padma Bhushan in Trade & Industry

UNION { ?award ps:P166 wd:Q949193. } # <<<<<< Award = Padma Shri UNION { ?award ps:P166 wd:Q30132541} # Art UNION { ?award ps:P166 wd:Q30132621} # Literature & Edu UNION { ?award ps:P166 wd:Q30132672} # Medicine UNION { ?award ps:P166 wd:Q30132492} # Science & Engineering UNION { ?award ps:P166 wd:Q30133065} # Sports UNION { ?award ps:P166 wd:Q30132984} # Social Work UNION { ?award ps:P166 wd:Q60671348} # Trade & Industry UNION { ?award ps:P166 wd:Q30132589} # Civil UNION { ?award ps:P166 wd:Q60671291} # Other UNION { ?award ps:P166 wd:Q60671325} # <<<<<< Padma Shri in Public Aff.

OPTIONAL { ?item wikibase:sitelinks ?linkcount. } # <<<<<< Link count

Award given in year filter

OPTIONAL { ?award pq:P585 ?time. }# <<<<<< Award has a time statement BIND(YEAR(?time) AS ?year)

filter(year(?time)=2022) # <<<<<< Filter for Award time = 2022

SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }

Items without the qualifer point in time # Source: Qualifers on a Heritage Register Item (Wikidata:Request_a_query/Archive/2019/01)

filter not exists {?item p:P166 [pq:P585 [] ].} # <<<<<< filter for items without the qualifier point in time

}

ORDER BY ASC(?itemLabel)

ORDER BY DESC(?year)

ORDER BY DESC(?linkcount)

Use at

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#>
# Padma awardees (using UNION), 3759 items @26JAN2022
SELECT ?item ?linkcount ?itemLabel ?itemDescription ?awardvalLabel ?year WHERE {
 ?item wdt:P31 wd:Q5.                   # <<<<<< Item = Human
 ?item p:P166 ?award.
 ?award ps:P166 ?awardval.

{ ?award ps:P166 wd:Q672392. }         # <<<<<< Award = Padma Vibhushan
UNION { ?award ps:P166 wd:Q84042880.}  # <<<<<< Padma Vibhushan_Public Affairs
UNION { ?award ps:P166 wd:Q30143915 }  # <<<<<< Padma Vibhushan_Literature
UNION { ?award ps:P166 wd:Q30147268 }  # <<<<<< Padma Vibhushan_Science and Engineering
UNION { ?award ps:P166 wd:Q30147343}   # <<<<<< Padma Vibhushan_Trade and Industry

UNION { ?award ps:P166 wd:Q932650. }   # <<<<<< Award = Padma Bhushan
UNION { ?award ps:P166 wd:Q30197118}   # <<<<<< Padma Bhushan in Sc. & Eng.
UNION { ?award ps:P166 wd:Q63877754}      # <<<<<< Award = Padma Bhushan in Lit. & Education
UNION { ?award ps:P166 wd:Q110686881}      # <<<<<< Award = Padma Bhushan in Trade & Industry

UNION { ?award ps:P166 wd:Q949193. }   # <<<<<< Award = Padma Shri
UNION { ?award ps:P166 wd:Q30132541}   # Art
UNION { ?award ps:P166 wd:Q30132621}   # Literature & Edu
UNION { ?award ps:P166 wd:Q30132672}   # Medicine
UNION { ?award ps:P166 wd:Q30132492}   # Science & Engineering
UNION { ?award ps:P166 wd:Q30133065}   # Sports
UNION { ?award ps:P166 wd:Q30132984}   # Social Work
UNION { ?award ps:P166 wd:Q60671348}   # Trade & Industry
UNION { ?award ps:P166 wd:Q30132589}   # Civil
UNION { ?award ps:P166 wd:Q60671291}   # Other
UNION { ?award ps:P166 wd:Q60671325}   # <<<<<< Padma Shri in Public Aff.

OPTIONAL { ?item wikibase:sitelinks ?linkcount. } # <<<<<< Link count 
# Award given in year filter 
OPTIONAL { ?award pq:P585 ?time. }# <<<<<< Award has a time statement 
BIND(YEAR(?time) AS ?year)
# filter(year(?time)=2022)                # <<<<<< Filter for Award time = 2022  
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
# Items without the qualifer point in time # Source: Qualifers on a Heritage Register Item (Wikidata:Request_a_query/Archive/2019/01)
#filter not exists {?item p:P166 [pq:P585 [] ].}  # <<<<<< filter for items without the qualifier point in time 
}
#ORDER BY ASC(?itemLabel)
ORDER BY DESC(?year)
#ORDER BY DESC(?linkcount)

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v3("?award") v4("?awardval") v2("?item"):::projected v5("?linkcount"):::projected v6("?time") v7("?year"):::projected c21(["wd:Q60671348"]):::iri c7(["wd:Q30143915"]):::iri c15(["wd:Q30132541"]):::iri c16(["wd:Q30132621"]):::iri c20(["wd:Q30132984"]):::iri c22(["wd:Q30132589"]):::iri c24(["wd:Q60671325"]):::iri c12(["wd:Q63877754"]):::iri c11(["wd:Q30197118"]):::iri c5(["wd:Q672392"]):::iri c8(["wd:Q30147268"]):::iri c28(["bd:serviceParam"]):::iri c2(["wd:Q5"]):::iri c10(["wd:Q932650"]):::iri c9(["wd:Q30147343"]):::iri c17(["wd:Q30132672"]):::iri c6(["wd:Q84042880"]):::iri c18(["wd:Q30132492"]):::iri c19(["wd:Q30133065"]):::iri c13(["wd:Q110686881"]):::iri c23(["wd:Q60671291"]):::iri c14(["wd:Q949193"]):::iri c30(["#91;AUTO_LANGUAGE#93;,en"]):::literal v2 --"p:direct/P31"--> c2 v2 --"p:P166"--> v3 v3 --"p:statement/P166"--> v4 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; subgraph union3[" Union "] subgraph union3l[" "] style union3l fill:#abf,stroke-dasharray: 3 3; subgraph union4[" Union "] subgraph union4l[" "] style union4l fill:#abf,stroke-dasharray: 3 3; subgraph union5[" Union "] subgraph union5l[" "] style union5l fill:#abf,stroke-dasharray: 3 3; subgraph union6[" Union "] subgraph union6l[" "] style union6l fill:#abf,stroke-dasharray: 3 3; subgraph union7[" Union "] subgraph union7l[" "] style union7l fill:#abf,stroke-dasharray: 3 3; subgraph union8[" Union "] subgraph union8l[" "] style union8l fill:#abf,stroke-dasharray: 3 3; subgraph union9[" Union "] subgraph union9l[" "] style union9l fill:#abf,stroke-dasharray: 3 3; subgraph union10[" Union "] subgraph union10l[" "] style union10l fill:#abf,stroke-dasharray: 3 3; subgraph union11[" Union "] subgraph union11l[" "] style union11l fill:#abf,stroke-dasharray: 3 3; subgraph union12[" Union "] subgraph union12l[" "] style union12l fill:#abf,stroke-dasharray: 3 3; subgraph union13[" Union "] subgraph union13l[" "] style union13l fill:#abf,stroke-dasharray: 3 3; subgraph union14[" Union "] subgraph union14l[" "] style union14l fill:#abf,stroke-dasharray: 3 3; subgraph union15[" Union "] subgraph union15l[" "] style union15l fill:#abf,stroke-dasharray: 3 3; subgraph union16[" Union "] subgraph union16l[" "] style union16l fill:#abf,stroke-dasharray: 3 3; subgraph union17[" Union "] subgraph union17l[" "] style union17l fill:#abf,stroke-dasharray: 3 3; subgraph union18[" Union "] subgraph union18l[" "] style union18l fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c24 end subgraph union18r[" "] style union18r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c23 end union18r <== or ==> union18l end end subgraph union17r[" "] style union17r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c22 end union17r <== or ==> union17l end end subgraph union16r[" "] style union16r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c21 end union16r <== or ==> union16l end end subgraph union15r[" "] style union15r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c20 end union15r <== or ==> union15l end end subgraph union14r[" "] style union14r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c19 end union14r <== or ==> union14l end end subgraph union13r[" "] style union13r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c18 end union13r <== or ==> union13l end end subgraph union12r[" "] style union12r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c17 end union12r <== or ==> union12l end end subgraph union11r[" "] style union11r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c16 end union11r <== or ==> union11l end end subgraph union10r[" "] style union10r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c15 end union10r <== or ==> union10l end end subgraph union9r[" "] style union9r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c14 end union9r <== or ==> union9l end end subgraph union8r[" "] style union8r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c13 end union8r <== or ==> union8l end end subgraph union7r[" "] style union7r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c12 end union7r <== or ==> union7l end end subgraph union6r[" "] style union6r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c11 end union6r <== or ==> union6l end end subgraph union5r[" "] style union5r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c10 end union5r <== or ==> union5l end end subgraph union4r[" "] style union4r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c9 end union4r <== or ==> union4l end end subgraph union3r[" "] style union3r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c8 end union3r <== or ==> union3l end end subgraph union2r[" "] style union2r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c7 end union2r <== or ==> union2l end end subgraph union1r[" "] style union1r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c6 end union1r <== or ==> union1l end end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; v3 --"p:statement/P166"--> c5 end union0r <== or ==> union0l end subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v2 -."wikibase:sitelinks".-> v5 end subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v3 -."p:qualifier/P585".-> v6 end bind0[/"year-from-dateTime(?time)"/] v6 --o bind0 bind0 --as--o v7 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c28 --"wikibase:language"--> c30 end