generated from FacultadInformatica-LinkedData/Template-Curso
-
Notifications
You must be signed in to change notification settings - Fork 66
/
Copy pathmacari-dev-YA6921023.txt
56 lines (41 loc) · 3.24 KB
/
macari-dev-YA6921023.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
1. Get all the properties that can be applied to instances of the Politician class
SELECT DISTINCT ?Property WHERE {
?Instance rdf:type <http://dbpedia.org/ontology/Politician>.
?Instance ?Property ?Object
}
Result: https://es.dbpedia.org/sparql?default-graph-uri=&query=SELECT+DISTINCT+%3FProperty+WHERE+%7B%0D%0A%3FInstance+rdf%3Atype+%3Chttp%3A%2F%2Fdbpedia.org%2Fontology%2FPolitician%3E.%0D%0A%3FInstance+%3FProperty+%3FObject%0D%0A%7D&should-sponge=&format=text%2Fhtml&timeout=0&debug=on&run=+Run+Query+
2. Get all the properties, except rdf:type, that can be applied to instances of the Politician class
SELECT DISTINCT ?Property WHERE {
?Instance rdf:type <http://dbpedia.org/ontology/Politician>.
?Instance ?Property ?Object.
FILTER (?Property!=rdf:type).
}
Result: https://es.dbpedia.org/sparql?default-graph-uri=&query=SELECT+DISTINCT+%3FProperty+WHERE+%7B%0D%0A%3FInstance+rdf%3Atype+%3Chttp%3A%2F%2Fdbpedia.org%2Fontology%2FPolitician%3E.%0D%0A%3FInstance+%3FProperty+%3FObject.%0D%0AFILTER+%28%3FProperty%21%3Drdf%3Atype%29.%0D%0A%7D&should-sponge=&format=text%2Fhtml&timeout=0&debug=on&run=+Run+Query+
3. Which different values exist for the properties, except for rdf:type, applicable to the instances of Politician?
SELECT DISTINCT ?objects
WHERE {
{
?politician rdf:type <http://dbpedia.org/ontology/Politician>.
?politician ?properties ?objects.
FILTER(?properties!=rdf:type).
}
}
Result: https://es.dbpedia.org/sparql?default-graph-uri=&query=SELECT+DISTINCT+%3Fobjects%0D%0Awhere+%7B%0D%0A%7B%0D%0A%3Fpolitician+rdf%3Atype+%3Chttp%3A%2F%2Fdbpedia.org%2Fontology%2FPolitician%3E.%0D%0A%3Fpolitician+%3Fproperties+%3Fobjects.%0D%0AFILTER%28%3Fproperties%21%3Drdf%3Atype%29.%0D%0A%7D%0D%0A%7D%0D%0A%0D%0A&should-sponge=&format=text%2Fhtml&timeout=0&debug=on&run=+Run+Query+
4. For each of these applicable properties, except for rdf:type, which different values do they take globally for all those instances?
SELECT DISTINCT ?property ?object
WHERE {
{
?politician rdf:type <http://dbpedia.org/ontology/Politician>.
?politician ?property ?object.
FILTER(?property != rdf:type).
}
}
Result: https://es.dbpedia.org/sparql?default-graph-uri=&query=SELECT+DISTINCT+%3Fproperty+%3Fobject%0D%0Awhere%7B%0D%0A++%7B%0D%0A++++%3Fpolitician+rdf%3Atype+%3Chttp%3A%2F%2Fdbpedia.org%2Fontology%2FPolitician%3E.%0D%0A++++%3Fpolitician+%3Fproperty+%3Fobject.%0D%0A++++FILTER%28%3Fproperty+%21%3D+rdf%3Atype%29.%0D%0A++%7D%0D%0A%7D&should-sponge=&format=text%2Fhtml&timeout=0&debug=on&run=+Run+Query+
5. For each of these applicable properties, except for rdf:type, how many distinct values do they take globally for all those instances?
SELECT DISTINCT ?property, COUNT(DISTINCT ?value) AS ?value_property
WHERE {
?p rdf:type <http://dbpedia.org/ontology/Politician>.
?p ?property ?value.
FILTER(?property != rdf:type)
}
Result: https://es.dbpedia.org/sparql?default-graph-uri=&query=SELECT+DISTINCT+%3Fproperty%2C+COUNT%28DISTINCT+%3Fvalue%29+AS+%3Fvalue_property%0D%0AWHERE+%7B%0D%0A%3Fp+rdf%3Atype+%3Chttp%3A%2F%2Fdbpedia.org%2Fontology%2FPolitician%3E.%0D%0A%3Fp+%3Fproperty+%3Fvalue.%0D%0AFILTER%28%3Fproperty+%21%3D+rdf%3Atype%29%0D%0A%7D%0D%0A&should-sponge=&format=text%2Fhtml&timeout=0&debug=on&run=+Run+Query+