diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/OEAW/ordered_sparql_insert_collection_oeaw_arche.sparql b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/OEAW/ordered_sparql_insert_collection_oeaw_arche.sparql index 636b373..6233c61 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/OEAW/ordered_sparql_insert_collection_oeaw_arche.sparql +++ b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/OEAW/ordered_sparql_insert_collection_oeaw_arche.sparql @@ -117,28 +117,81 @@ WHERE { }; PREFIX aocat: - INSERT { - GRAPH { - ?temporal aocat:has_period ?period . - ?temporal aocat:from ?temporalFrom . - ?temporal aocat:until ?temporalUntil . - } - } - WHERE { - GRAPH { - ?temporal aocat:has_period ?period . - ?temporal aocat:from ?temporalFrom . - ?temporal aocat:until ?temporalUntil . - } - }; - - PREFIX aocat: - PREFIX skos: +PREFIX skos: WITH DELETE { ?period skos:prefLabel ?label} WHERE { ?temporal aocat:has_period ?period . - ?period skos:prefLabel ?label -} + ?period skos:prefLabel ?label +}; +PREFIX aocat: +PREFIX skos: + INSERT { + GRAPH { + ?nativePeriod skos:prefLabel ?periodLabel . + } + } + WHERE { + GRAPH { + ?temporal aocat:has_native_period ?nativePeriod . + ?nativePeriod skos:prefLabel ?periodLabel . + } + }; + PREFIX skos: + PREFIX aocat: + PREFIX time: + PREFIX ariadneplus: +INSERT { + GRAPH { + ?temporal aocat:has_period ?periodOURI . + ?temporal aocat:from ?temporalFrom . + ?temporal aocat:until ?temporalUntil . + } + } + USING + USING + WHERE { + ?temporal aocat:has_period ?periodOURI . + ?periodOURI time:intervalStartedBy ?intervalStartedBy . + ?intervalStartedBy time:hasDateTimeDescription ?startDescr . + ?startDescr time:year ?temporalFrom . + ?periodOURI time:intervalFinishedBy ?intervalFinishedBy . + ?intervalFinishedBy time:hasDateTimeDescription ?finishDescr . + ?finishDescr time:year ?temporalUntil + }; + + PREFIX aocat: + INSERT { + GRAPH { + ?temporal aocat:has_period ?nativePeriod . + ?temporal aocat:from ?temporalFrom . + ?temporal aocat:until ?temporalUntil . + } + } + WHERE { + GRAPH { + ?temporal aocat:has_native_period ?nativePeriod . + ?temporal aocat:from ?temporalFrom . + ?temporal aocat:until ?temporalUntil . + } + }; + + PREFIX aocat: + PREFIX skos: + WITH + DELETE { ?lang skos:prefLabel ?label} + WHERE { + ?s aocat:has_language ?lang . + ?lang skos:prefLabel ?label + }; + + PREFIX aocat: + PREFIX skos: + INSERT DATA { + GRAPH { + skos:prefLabel "en" . + skos:prefLabel "de" . + } + }; \ No newline at end of file