generated from FacultadInformatica-LinkedData/Template-Curso
-
Notifications
You must be signed in to change notification settings - Fork 26
/
Copy pathAlejandroCalderon_SPARQL.txt
42 lines (34 loc) · 1.4 KB
/
AlejandroCalderon_SPARQL.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
## 1. Get all the properties that can be applied to instances of the Politician class
SELECT DISTINCT ?property WHERE
{
?instance a <http://dbpedia.org/ontology/Politician> .
?instance ?property ?value
}
## 2. Get all the properties, except rdf:type, that can be applied to instances of the Politician class
SELECT DISTINCT ?property WHERE
{
?instance a <http://dbpedia.org/ontology/Politician> .
?instance ?property ?value .
FILTER (?property != rdf:type)
}
## 3. Which different values exist for the properties, except rdf:type, of the instances of the Politician class?
SELECT DISTINCT ?value WHERE
{
?instance a <http://dbpedia.org/ontology/Politician> .
?instance ?property ?value .
FILTER (?property != rdf:type)
}
## 4. For each of the properties, except rdf:type, that can be applied to instances of the Politician class, which different values do they take in those instances?
SELECT DISTINCT ?property ?value WHERE
{
?instance a <http://dbpedia.org/ontology/Politician> .
?instance ?property ?value .
FILTER (?property != rdf:type)
}
## 5. For each of the properties, except rdf:type, that can be applied to instances of the Politician class, how many distinct values do they take in those instances?
SELECT DISTINCT ?property COUNT(?value) WHERE
{
?instance a <http://dbpedia.org/ontology/Politician> .
?instance ?property ?value .
FILTER (?property != rdf:type)
}