https://linked.ope...aph-browser/query
| - PREFIX z: <https://slovník.gov.cz/základní/pojem/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX dce: <http://purl.org/dc/elements/1.1/>
PREFIX dct: <http://purl.org/dc/terms/>
PREFIX browser-sgov: <https://linked.opendata.cz/ontology/knowledge-graph-browser/sgov-en/>
PREFIX browser: <https://linked.opendata.cz/ontology/knowledge-graph-browser/>
PREFIX fel: <http://onto.fel.cvut.cz/ontologies/slovník/agendový/popis-dat/pojem/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
CONSTRUCT {
?node skos:prefLabel ?label ;
browser-sgov:vocabularyLabel ?vocabularyLabel ;
skos:definition ?definition ;
browser-sgov:legal ?legal ;
browser-sgov:numberOfAttributes ?numberOfAttributes ;
browser-sgov:numberOfOutwardsRelations ?numberOfOutwardsRelations ;
browser-sgov:numberOfInwardsRelations ?numberOfInwardsRelations ;
browser-sgov:numberOfChildren ?numberOfChildren ;
browser-sgov:numberOfParents ?numberOfParents .
} WHERE {
?node skos:prefLabel ?label ;
skos:inScheme ?glossary .
FILTER (LANG(?label) = "en")
?vocabulary a fel:slovník ;
owl:imports ?glossary ;
dct:title ?vocabularyLabel .
FILTER (LANG(?vocabularyLabel) = "cs")
OPTIONAL {
?node skos:definition ?definition .
FILTER (LANG(?definition) = "en")
}
OPTIONAL {
?node dct:source|dct:relation ?source .
BIND(SUBSTR(REPLACE(REPLACE(STR(?source), "https://esbirka.opendata.cz/zdroj/předpis/[0-9]+/[0-9]+/sekce((/[^/]+)+)", "$1"), "/", "-"), 2) AS ?anchor)
BIND(STRDT(CONCAT(REPLACE(STR(?source), "https://esbirka.opendata.cz/zdroj/předpis/([0-9]+)/([0-9]+)/sekce((/[^/]+)+)", "https://zakonyprolidi.cz/cs/$2-$1#p"), ?anchor), xsd:anyURI) AS ?legal)
}
OPTIONAL {
SELECT ?node (COUNT(DISTINCT ?child) AS ?numberOfChildren)
WHERE {
?child rdfs:subClassOf ?node .
FILTER(!isBlank(?node))
}
GROUP BY ?node
}
OPTIONAL {
SELECT ?node (COUNT(DISTINCT ?parent) AS ?numberOfParents)
WHERE {
?node rdfs:subClassOf ?parent .
FILTER(!isBlank(?parent))
}
GROUP BY ?node
}
OPTIONAL {
SELECT ?node (COUNT(DISTINCT ?attribute) AS ?numberOfAttributes)
WHERE {
?attribute a z:typ-vlastnosti ;
rdfs:subClassOf [
owl:allValuesFrom ?node ;
owl:onProperty z:je-vlastností
] .
}
GROUP BY ?node
}
OPTIONAL {
SELECT ?node (COUNT(DISTINCT ?relation) AS ?numberOfOutwardsRelations)
WHERE {
?relation a z:typ-vztahu ;
rdfs:subClassOf [
owl:allValuesFrom ?node ;
owl:onProperty z:má-vztažený-prvek-1
] .
}
GROUP BY ?node
}
OPTIONAL {
SELECT ?node (COUNT(DISTINCT ?relation) AS ?numberOfInwardsRelations)
WHERE {
?relation a z:typ-vztahu ;
rdfs:subClassOf [
owl:allValuesFrom ?node ;
owl:onProperty z:má-vztažený-prvek-2
] .
}
GROUP BY ?node
}
}
|