fix language code label, now retrieved parsing has_language property value

This commit is contained in:
Enrico Ottonello 2021-01-31 16:38:47 +01:00
parent cd66308827
commit 18801c68cc
1 changed files with 60 additions and 1 deletions

View File

@ -125,6 +125,27 @@ WHERE {
} }
}; };
PREFIX aocat: <https://www.ariadne-infrastructure.eu/resource/ao/cat/1.1/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
INSERT {
GRAPH <https://ariadne-infrastructure.eu/api_________::ariadne_plus::dans::easy> {
?isoLangRef skos:prefLabel ?lang .
}
}
WHERE {
GRAPH <https://ariadne-infrastructure.eu/api_________::ariadne_plus::dans::easy> {
?s rdf:type aocat:AO_Individual_Data_Resource .
?s aocat:has_language ?isoLangRef .
MINUS {
?s rdf:type aocat:AO_Individual_Data_Resource .
?s aocat:has_language ?isoLangRef .
?isoLangRef skos:prefLabel ?p .
}
bind (strafter(str(?isoLangRef),"iso639-1/") as ?lang)
}
};
PREFIX aocat: <https://www.ariadne-infrastructure.eu/resource/ao/cat/1.1/> PREFIX aocat: <https://www.ariadne-infrastructure.eu/resource/ao/cat/1.1/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#> PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
@ -144,6 +165,42 @@ WHERE {
} }
}; };
PREFIX aocat: <https://www.ariadne-infrastructure.eu/resource/ao/cat/1.1/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
INSERT {
GRAPH <https://ariadne-infrastructure.eu/ariadneplus::dans::aatplus> {
?record aocat:has_derived_subject ?aat .
}
}
WHERE {
graph <https://ariadne-infrastructure.eu/api_________::ariadne_plus::dans::easy> {
?record aocat:has_native_subject ?ns_label .
bind(strafter(str(?ns_label),"Match: ") as ?m)
filter(str(?m)=str(?aat_label))
}
graph <https://ariadne-infrastructure.eu/api_________::ariadne_plus::dans::aat> {
{
?subject skos:broadMatch ?aat .
?aat skos:prefLabel ?aat_label .
}
union
{
?subject skos:exactMatch ?aat .
?aat skos:prefLabel ?aat_label .
}
union
{
?subject skos:closeMatch ?aat .
?aat skos:prefLabel ?aat_label .
}
union
{
?subject skos:narrowMatch ?aat .
?aat skos:prefLabel ?aat_label .
}
}
};
PREFIX dcterms: <http://purl.org/dc/terms/> PREFIX dcterms: <http://purl.org/dc/terms/>
INSERT { INSERT {
GRAPH <https://ariadne-infrastructure.eu/ariadneplus::dans::periodo> { GRAPH <https://ariadne-infrastructure.eu/ariadneplus::dans::periodo> {
@ -188,4 +245,6 @@ PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
} }
} }
} }
}; };