User
Difference between revisions of "Lepticed7"
Line 12: | Line 12: | ||
<query _pagination="10" locutor="Item (locutor Qid)" locutorLabel="Speaker" nb="Number of records" languages="Spoken languages"></translate> | <query _pagination="10" locutor="Item (locutor Qid)" locutorLabel="Speaker" nb="Number of records" languages="Spoken languages"></translate> | ||
− | + | SELECT ?locutor ?locutorLabel ?nb WHERE { | |
− | + | { | |
+ | SELECT ?locutor (COUNT(?record) as ?nb) | ||
+ | WHERE { | ||
?record prop:P2 entity:Q2 . | ?record prop:P2 entity:Q2 . | ||
?record prop:P5 ?locutor . | ?record prop:P5 ?locutor . | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
} | } | ||
GROUP BY ?locutor ?locutorLabel | GROUP BY ?locutor ?locutorLabel | ||
ORDER BY DESC(?nb) | ORDER BY DESC(?nb) | ||
− | LIMIT | + | LIMIT 5 |
+ | } | ||
+ | SERVICE wikibase:label { | ||
+ | bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" . | ||
+ | ?locutor rdfs:label ?locutorLabel . | ||
+ | } | ||
+ | } | ||
+ | ORDER BY DESC(?nb) | ||
</query> | </query> |