Babel user information
it-N Questo utente può contribuire con un livello madrelingua in italiano.
en-3 This user has advanced knowledge of English.
de-1 Dieser Benutzer beherrscht Deutsch auf grundlegendem Niveau.
fr-1 Cet utilisateur dispose de connaissances de base en français.
es-1 Esta persona tiene un conocimiento básico del español.
Questo utente partecipa alle attività del Gruppo Wikidata per Musei, Archivi e Biblioteche
Scholia logoThis user uses Scholia.
This user adds items about citateable works quickly and easily with Zotero.
This user uses Mix'n'match.
This user loves OpenRefine.
This user loves Wikidata.
Users by language

GWMAB edit

Gruppo Wikidata Archivi Musei Biblioteche
Pagina ufficiale di GWMAB presso il Dipartimento di Musicologia e Beni Culturali della University of Pavia (Q219317)

Preferred tools edit

Help edit

Useful links for reconciliation with OpenRefine edit

Colon Classification in Wikidata edit

CC author and class numbers of main class O Literature: https://w.wiki/3FaH

For a description of the gadget and of the project see

Basic SPARQL Queries for beginners edit

# Estrae l'ID di Wikidata per le persone che hanno frequentato l’Università di Pavia
SELECT ?persone  # estrai l'ID
WHERE { 
?persone wdt:P69 wd:Q219317  . # la variabile ?persone deve soddisfare la condizione di avere frequentato l'Università di Pavia
 }
LIMIT 50 # limita la pagina dei risultati ai primi 50
Try it!


## Estrae l'ID di Wikidata e l'etichetta degli item che sono gatti 
SELECT ?item ?itemLabel # estrai l'ID e la relativa etichetta
WHERE 
{
  ?item wdt:P31 wd:Q146.
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!


# Giornalisti
SELECT ?item ?itemLabel
WHERE {
  ?item wdt:P31 wd:Q5 . # tutti gli item che sono di tipo 'umano'
  ?item wdt:P106 wd:Q1930187 . # tutti gli item che ANCHE hanno come occupazione "giornalista" 
SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],it,en". }
}
LIMIT 50
Try it!


# Giornalisti italiani						
SELECT ?item ?itemLabel
WHERE {
  ?item wdt:P31 wd:Q5 . #  item di tipo 'umano'
  ?item wdt:P106 wd:Q1930187 . # item con occupazione "giornalista" 
  ?item wdt:P27 wd:Q38 . # item con paese di cittadinanza "Italia"
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
LIMIT 50
Try it!


# Giornalisti nati a Ravenna						
# N.B. TOTALE 14
SELECT ?item ?itemLabel
WHERE {
  ?item wdt:P31 wd:Q5 . #  item di tipo 'umano'
  ?item wdt:P106 wd:Q1930187 . # item con occupazione "giornalista" 
  ?item wdt:P19 wd:Q13364 . # luogo di nascita "Ravenna"
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],it,en". }
}
LIMIT 50
Try it!


# Scrittori nati a Parigi e morti a Mosca
SELECT ?item ?itemLabel
WHERE {
  ?item wdt:P31 wd:Q5 . #  item di tipo 'umano'
  ?item wdt:P106 wd:Q36180 . # item con occupazione "giornalista" 
  ?item wdt:P19 wd:Q90 . # luogo di nascita "Ravenna"
  ?item wdt:P20 wd:Q649 .
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],it,en". }
}
LIMIT 50
Try it!


# Cani attori
SELECT ?item ?itemLabel 
WHERE 
{
  ?item wdt:P31 wd:Q144 . # item di tipo "cane"
  ?item wdt:P106 wd:Q33999 . # occupazione attore
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!


#Mappa di ospedali in Italia (attenzione lenta). Mostra le lacune nei dati di Wikidata (es. Friuli Venezia Giulia)
#defaultView:Map
SELECT * WHERE {
  ?item wdt:P31/wdt:P279* wd:Q16917;
        wdt:P17 wd:Q38 ;
        wdt:P625 ?geo .
}
Try it!


# Giornalisti italiani, esclusi quelli nati a Ravenna
SELECT ?item ?itemLabel
WHERE {
  ?item wdt:P31 wd:Q5 . # tutti gli item che sono di tipo 'umano'
  ?item wdt:P106 wd:Q1930187 . # occupazione "giornalista" 
  ?item wdt:P27 wd:Q38 .
  MINUS { ?item wdt:P19 wd:Q13364 . } # eccetto luogo di nascita "Ravenna"
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!


# Giornalisti nati a Ravenna che hanno o non hanno la dichiarazione relativa al paese di cittadinanza (13 item)
SELECT ?item ?itemLabel
WHERE {
  ?item wdt:P31 wd:Q5 . # item di tipo 'umano'
  ?item wdt:P106 wd:Q1930187 . # occupazione "giornalista" 
  ?item wdt:P19 wd:Q13364 . # eccetto luogo di nascita "Ravenna"
  OPTIONAL { ?item wdt:P27 wd:Q38 .} # trova gli item per cui la cittad. italiana è facoltativa
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!


# Giornalisti nati a Ravenna che sono privi della dichiarazione relativa al paese di cittadinanza
SELECT ?item ?itemLabel
WHERE {
   ?item wdt:P31 wd:Q5 . #  item di tipo 'umano'
  ?item wdt:P106 wd:Q1930187 . # item con occupazione "giornalista" 
  ?item wdt:P19 wd:Q13364 . # luogo di nascita "Ravenna"
  FILTER NOT EXISTS { ?item wdt:P27 wd:Q38 .} # trova gli item per cui la tripla cittad. italiana manca
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!


# Giornalisti italiani il cui padre era giornalista (due variabili: il giornalista, e il padre)
SELECT ?item ?itemLabel ?padreLabel
WHERE {
  ?item wdt:P31 wd:Q5 . # tutti gli item che sono di tipo 'umano'
  ?item wdt:P27 wd:Q38 . # cittadinanza - Italia
  ?item wdt:P106 wd:Q1930187 . # occupazione - giornalista 
  ?item wdt:P22 ?padre . # l'item che cerchiamo deve avere un padre, uno qualsiasi, non uno specifico, cioè una variabile ?padre
  ?padre wdt:P106 wd:Q1930187 . #il padre che cerchiamo deve essere un giornalista
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!


# Giornalisti italiani figli d’arte nati dopo il 1949 – FILTER DATE
SELECT ?item ?itemLabel ?padreLabel ?ddn
WHERE {
  ?item wdt:P31 wd:Q5 . # tutti gli item che sono di tipo 'umano'
  ?item wdt:P27 wd:Q38 . # cittadinanza - Italia
  ?item wdt:P106 wd:Q1930187 . # occupazione - giornalista 
  ?item wdt:P22 ?padre . # l'item deve avere «un» padre x
  ?padre wdt:P106 wd:Q1930187 . # il padre deve essere giornalista
 ?item wdt:P569 ?ddn . # l'item ha una data di nascita x, quindi variab.
  FILTER (YEAR(?ddn) > 1949). #  Data di nascita successiva al 1949 .
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!


#Numero di opere letterarie in Wikidata  - COUNT
SELECT (COUNT(?item) AS ?count)
WHERE {
  ?item wdt:P31 wd:Q7725634 . # (P31) è di tipo (Q7725634) opera letteraria
}
Try it!


#Numero di opere letterarie e di tutte gli item nelle sue sottoclassi in Wikidata
SELECT (COUNT(?item) AS ?count)
WHERE {
  ?item wdt:P31/wdt:P279* wd:Q7725634 . # (P31) è di tipo (Q7725634) opera letteraria o una sua sottoclasse qualsiasi (P279*)
}
Try it!


#Contare e comparare graficamente
#Colori degli occhi più comuni. Grafico a bolle, conteggio; il comando che segue è letto da WKD (anche se inizia con #) e significa mostra i risultati in forma di grafico a bolle
#defaultView:BubbleChart
SELECT ?eyeColorLabel (COUNT(?human) AS ?totale) #mostra il colore degli occhi e conta il totale di ?human
WHERE {
  ?human wdt:P31 wd:Q5. #definisce ?human come Q5
  ?human wdt:P1340 ?eyeColor. # definisce il colore degli occhi come proprietà di ?human
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
GROUP BY ?eyeColorLabel  # raggruppa per colore degli occhi
ORDER BY DESC(?totale) # ordina in numero decrescente
Try it!


# Grafico a bolle delle parole chiave in base al numero associati agli articoli di Jlis.it
#defaultView:BubbleChart
SELECT ?parChiaveLabel (COUNT(?art) AS ?count)
WHERE {
 ?art wdt:P31 wd:Q13442814 .
  ?art wdt:P1433 wd:Q3805294 .
  ?art wdt:P921 ?parChiave .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],it,en". }
}
GROUP BY ?parChiaveLabel
ORDER BY DESC(?count)
Try it!


# Grafico a bolle delle parole chiave che compaiono più di 2 volte negli articoli di Jlis
#defaultView:BubbleChart
SELECT ?parChiaveLabel (COUNT(?art) AS ?count)
WHERE {
 ?art wdt:P31 wd:Q13442814 .
  ?art wdt:P1433 wd:Q3805294 .
  ?art wdt:P921 ?parChiave .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],it,en". }
}
GROUP BY ?parChiaveLabel
HAVING (?count > 2)
ORDER BY DESC(?count)
Try it!
#Articoli di riviste italiane relative alla scienza dell'informazione e delle biblioteche con più di una data di pubblicazione
SELECT DISTINCT ?articolo ?articoloLabel ?rivista ?rivistaLabel
WHERE {
  ?rivista wdt:P31 wd:Q5633421 .
  ?rivista wdt:P495 wd:Q38 .
  ?rivista wdt:P921 wd:Q13420675 .
  ?articolo wdt:P31 wd:Q13442814 .
  ?articolo wdt:P1433 ?rivista .
  ?articolo wdt:P577 ?d .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
GROUP BY ?articolo ?articoloLabel ?rivista ?rivistaLabel
HAVING(COUNT(?d) > 1)
ORDER BY ?articoloLabel
Try it!


# Mappa dei luoghi di nascita dei giornalisti italiani (un po’ lenta …)
#defaultView:Map
SELECT ?item ?itemLabel ?coord
WHERE {
  ?item wdt:P31 wd:Q5 . # item di tipo 'umano'
  ?item wdt:P106 wd:Q1930187 . # occupazione "giornalista" 
  ?item wdt:P27 wd:Q38 . # di cittadinanza "Italia"
  ?item wdt:P19 ?luogodinasc . # luogo di nascita
  ?luogodinasc wdt:P625 ?coord . #coordinate del luogo di nascita
  SERVICE wikibase:label {bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
LIMIT 500
Try it!


#Cronologia delle opere di Tiziano Vecellio, che abbiano data tra il 1500 e il 1600, con eventuale immagine
#defaultView:Timeline
SELECT DISTINCT ?item ?itemLabel ?data_creazione ?immagine WHERE {
  ?item wdt:P170 wd:Q47551.
  ?item wdt:P571 ?data_creazione .
    OPTIONAL { ?item wdt:P18 ?immagine. }
  FILTER(?data_creazione >= "1500-01-01"^^xsd:dateTime && ?data_creazione < "1600-01-01"^^xsd:dateTime)
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],it,en". }
}
Try it!


#Articoli di Jlis.it con data, volume, fascicolo e pagine per controllo completezza descrizione
SELECT DISTINCT ?articolo ?articoloLabel ?anno ?volume ?fascicolo ?pagine WHERE {
  ?articolo wdt:P1433 wd:Q3805294.
  ?articolo wdt:P577 ?anno .
  OPTIONAL { ?articolo wdt:P478 ?volume . }
  OPTIONAL { ?articolo wdt:P433 ?fascicolo . }
  OPTIONAL {?articolo wdt:P304 ?pagine . }
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY (?anno)(?volume)(?fascicolo)(?pagine)
Try it!

More advanced SPARQL Queries edit

# Conteggio di Poli SBN per regione
SELECT ?sedeLabel (COUNT(?polo) AS ?totale) #mostra la sede e conta il totale di poli
WHERE {
  ?polo wdt:P31 wd:Q113223474. #definisce ?polo come polo SBN 
  ?polo wdt:P131 ?sede. # definisce sede come proprietà di polo
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
GROUP BY ?sedeLabel  # raggruppa per sede
ORDER BY DESC(?totale) # ordina in numero decrescente
Try it!


#Articoli di Jlis.it con data, volume, fascicolo, pagine, numero di pagine e lingua per controllo completezza descrizione
# in ordine di anno, volume e fascicolo, filtrabile per anno attivando il filtro
SELECT DISTINCT ?articolo ?articoloLabel ?anno ?volume ?fascicolo ?pagine ?totPag ?linguaLabel WHERE {
  ?articolo wdt:P1433 wd:Q3805294.
  ?articolo wdt:P577 ?anno .
  OPTIONAL { ?articolo wdt:P478 ?volume . }
  OPTIONAL { ?articolo wdt:P433 ?fascicolo . }
  OPTIONAL {?articolo wdt:P304 ?pagine . }
  OPTIONAL {?articolo wdt:P1104 ?totPag . }
  OPTIONAL {?articolo wdt:P407 ?lingua . }
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
#  FILTER (YEAR(?anno) > 2019) .
#  FILTER (YEAR(?anno) < 2021) .
}
ORDER BY DESC(?anno)(?volume)(?fascicolo)
Try it!
#Mappa di ospedali nel raggio di 50 km da Pavia
#defaultView:Map
SELECT distinct ?item ?itemLabel ?location WHERE {
  wd:Q6259 wdt:P625 ?coordPv .                      # coordinates of Pavia
  ?item wdt:P31/wdt:P279* wd:Q16917;                # item is a hospital
        wdt:P625 ?location .
  FILTER(geof:distance(?location, ?coordPv) < 50). # less than 50 km away from Pavia
  SERVICE wikibase:label { bd:serviceParam wikibase:language "it, en". }
}
Try it!
#Mappa delle installazioni di IRIS in Italia
#defaultView:Map{ "markercluster": true}
SELECT ?iris ?irisLabel ?uni ?uniLabel ?sigla ?luogo ?luogoLabel ?coord ?layer
WHERE {
  ?iris wdt:P408 wd:Q107492957 .
  ?iris wdt:P126 ?uni .
  OPTIONAL { ?uni wdt:P1813 ?sigla . }
  OPTIONAL { ?iris wdt:P1687 ?p . }
  OPTIONAL { ?uni wdt:P131 ?luogo . ?luogo wdt:P625 ?coord . }
  BIND(IF(BOUND(?p),'P','no P') AS ?layer)
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Try it!
#Opere di autori nati negli Stati Uniti nella prima metà dell’800 e pubblicate in Germania
SELECT DISTINCT ?opera ?operaLabel ?autore ?autoreLabel ?dataNasc ?luogoPubbLabel
WHERE
{
  ?opera wdt:P31 wd:Q3331189 .
  ?opera wdt:P291 ?luogoPubb .
  ?luogoPubb wdt:P17 wd:Q183 .
  ?opera wdt:P50 ?autore .
  ?autore wdt:P19 ?luogoNasc .
  ?luogoNasc wdt:P17 wd:Q30 .
  ?autore wdt:P569 ?dataNasc .
  FILTER ((?dataNasc >= "1799-12-31T00:00:00Z"^^xsd:dateTime) && (?dataNasc < "1851-01-01T00:00:00Z"^^xsd:dateTime))
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],it,en,de". }
}
Try it!
#Località italiane con nomi che finiscono in "-acco"
#defaultView:Map
SELECT DISTINCT ?item ?itemLabel ?coord
WHERE
{
  { ?item wdt:P31/wdt:P279* wd:Q1134686 . } UNION { ?item wdt:P31/wdt:P279* wd:Q15284 . } 
   ?item     wdt:P17 wd:Q38;
        rdfs:label ?itemLabel;
        wdt:P625 ?coord;
  FILTER (lang(?itemLabel) = "it").
  FILTER regex (?itemLabel, "acco$").
}
Try it!
# Elenca in ordine alfabetico i musei che possiedono dipinti del XVII e XVIII secolo che hanno per soggetto Betsabea al bagno
SELECT DISTINCT ?item ?itemLabel ?data_creazione ?istituto ?istitutoLabel 
WHERE {
  ?item wdt:P31/wdt:P279* wd:Q3305213 . # item è un dipinto o una sottoclasse
  ?item wdt:P571 ?data_creazione . # definisce la variabile data di creazione
  ?item wdt:P921 wd:Q69805487 . # definisce l'argomento principale dell'item
  ?item wdt:P276 ?istituto . # definisce la variabile Istituto
  FILTER(?data_creazione >= "1600-01-01"^^xsd:dateTime && ?data_creazione < "1801-01-01"^^xsd:dateTime)
  SERVICE wikibase:label { bd:serviceParam wikibase:language "it,en". }
}
ORDER BY ?istitutoLabel
Try it!
#Biblioteche in Emilia-Romagna e facenti parte della rete NILDE
#defaultView:Map
SELECT DISTINCT ?item ?itemLabel ?itemDescription ?comuneLabel ?coord ?layer WHERE {
  {?item wdt:P31/wdt:P279* wd:Q7075} UNION {?item wdt:P31 wd:Q856584 .}
   ?item (wdt:P131)* wd:Q1263 .
   OPTIONAL { ?item wdt:P463 wd:Q21272726 . BIND("NILDE" as ?layer) } .
   ?item wdt:P131 ?comune .
   ?comune wdt:P625 ?comunecoord .
  OPTIONAL { ?item wdt:P625 ?itemcoord . }
  BIND(IF(BOUND(?itemcoord),?itemcoord,?comunecoord) AS ?coord)
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en, it, fr, es, de". }
}
Try it!

Suggested tools for beginners (especially librarians) edit


My global contributions

Authority control

Indice delle sottopagine edit

https://www.wikidata.org/wiki/Special:PrefixIndex/User:Carlobia