diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/ADS/ordered_sparql_insert_archives.sparql b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/ADS/ordered_sparql_insert_archives.sparql index 7ff48ae..38fc6c5 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/ADS/ordered_sparql_insert_archives.sparql +++ b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/enrich/ADS/ordered_sparql_insert_archives.sparql @@ -1,104 +1,15 @@ PREFIX aocat: -PREFIX skos: -PREFIX ariadneplus: -INSERT { - GRAPH { - ?record aocat:has_access_rights ?coll_value . - } +DELETE { + aocat:was_modified ?x . } -USING -USING WHERE { - ?record aocat:is_part_of ?collection . - ?collection aocat:has_access_rights ?coll_value . - MINUS { - ?record aocat:has_access_rights ?rec_value . - } + aocat:was_modified ?x . }; PREFIX aocat: -PREFIX skos: -PREFIX ariadneplus: -INSERT { - GRAPH { - ?record aocat:has_ARIADNE_subject ?coll_value . - } -} -USING -USING -WHERE { - ?record aocat:is_part_of ?collection . - ?collection aocat:has_ARIADNE_subject ?coll_value . - MINUS { - ?record aocat:has_ARIADNE_subject ?rec_value . - } -}; - -PREFIX skos: -PREFIX aocat: -INSERT { - GRAPH { - ?ariadneSubject skos:prefLabel ?label . - } -} -WHERE { - GRAPH { - ?s aocat:has_ARIADNE_subject ?ariadneSubject . - GRAPH ?g { - ?ariadneSubject skos:prefLabel ?label . - } - } -}; - -PREFIX aocat: -PREFIX skos: -PREFIX ariadneplus: -PREFIX rdf: -PREFIX rdfs: -INSERT { - GRAPH { - ?record aocat:has_owner ?coll_value . - ?coll_value rdf:type ?type . - ?coll_value rdfs:label ?label . - ?coll_value aocat:has_name ?name . - } -} -USING -USING -WHERE { - ?record aocat:is_part_of ?collection . - ?collection aocat:has_owner ?coll_value . - ?coll_value rdf:type ?type . - ?coll_value rdfs:label ?label . - ?coll_value aocat:has_name ?name . - MINUS { - ?record aocat:has_owner ?rec_value . - } -}; - -PREFIX aocat: -PREFIX skos: -PREFIX ariadneplus: -PREFIX rdf: -PREFIX rdfs: -INSERT { - GRAPH { - ?record aocat:has_responsible ?coll_value . - ?coll_value rdf:type ?type . - ?coll_value rdfs:label ?label . - ?coll_value aocat:has_name ?name . - } -} -USING -USING -WHERE { - ?record aocat:is_part_of ?collection . - ?collection aocat:has_responsible ?coll_value . - ?coll_value rdf:type ?type . - ?coll_value rdfs:label ?label . - ?coll_value aocat:has_name ?name . - MINUS { - ?record aocat:has_responsible ?rec_value . +INSERT DATA { +GRAPH { + aocat:was_modified "2022-11-08"^^xsd:dateTime . } }; @@ -123,45 +34,6 @@ INSERT { } }; -PREFIX aocat: -PREFIX skos: -PREFIX rdf: -PREFIX rdfs: -INSERT { - GRAPH { - ?s aocat:was_modified ?issued . - } -} -USING -WHERE { - ?s rdf:type aocat:AO_Individual_Data_Resource . - ?s aocat:was_issued ?issued . - MINUS { - ?s rdf:type aocat:AO_Individual_Data_Resource . - ?s aocat:was_modified ?modified . - } -}; - -PREFIX aocat: -PREFIX skos: -PREFIX ariadneplus: -INSERT { - GRAPH { - ?record aocat:was_issued ?coll_issued_value . - ?record aocat:was_modified ?coll_modified_value . - } -} -USING -USING -WHERE { - ?record aocat:is_part_of ?collection . - ?collection aocat:was_issued ?coll_issued_value . - ?collection aocat:was_modified ?coll_modified_value . - MINUS { - ?record aocat:was_issued ?rec_value . - ?record aocat:was_modified ?rec_value2 . - } -}; PREFIX aocat: PREFIX skos: @@ -187,8 +59,8 @@ PREFIX skos: PREFIX rdf: INSERT { GRAPH { - ?s aocat:has_native_subject . - skos:prefLabel "Not provided" . + ?s aocat:has_native_subject . + skos:prefLabel "Not provided" . } } WHERE { @@ -201,28 +73,6 @@ WHERE { } }; -PREFIX aocat: -PREFIX rdf: -PREFIX rdfs: -INSERT { - GRAPH { - ?s aocat:has_spatial_coverage . - rdf:type . - rdfs:label "Name not provided" . - aocat:has_place_name "Name not provided" . - } -} -WHERE { - GRAPH { - ?s rdf:type aocat:AO_Individual_Data_Resource . - MINUS { - ?s rdf:type aocat:AO_Individual_Data_Resource . - ?s aocat:has_spatial_coverage ?spatialRegion . - ?spatialRegion aocat:has_place_name ?placeName . - } - } -}; - PREFIX aocat: PREFIX skos: PREFIX rdf: @@ -267,6 +117,93 @@ INSERT { } }; +PREFIX aocat: +PREFIX skos: +PREFIX rdf: +PREFIX rdfs: +INSERT { + GRAPH { + ?s aocat:has_responsible . + rdf:type . + rdfs:label "Not provided" . + aocat:has_name "Not provided" . + } + } + WHERE { + GRAPH { + ?s rdf:type aocat:AO_Individual_Data_Resource . + MINUS { + ?s rdf:type aocat:AO_Individual_Data_Resource . + ?s aocat:has_responsible ?resp . + } + } +}; + +PREFIX aocat: +PREFIX skos: +PREFIX rdf: +PREFIX rdfs: +INSERT { + GRAPH { + ?s aocat:has_owner . + rdf:type . + rdfs:label "Not provided" . + aocat:has_name "Not provided" . + } + } + WHERE { + GRAPH { + ?s rdf:type aocat:AO_Individual_Data_Resource . + MINUS { + ?s rdf:type aocat:AO_Individual_Data_Resource . + ?s aocat:has_owner ?own . + } + } +}; + + +PREFIX aocat: + PREFIX skos: + PREFIX ariadneplus: + + INSERT { + GRAPH { + ?record aocat:was_modified ?coll_mod . + } + } + USING + USING + WHERE { + ?record rdf:type aocat:AO_Individual_Data_Resource . + ?record aocat:is_part_of ?coll . + ?coll aocat:was_modified ?coll_mod . + MINUS{ + ?record rdf:type aocat:AO_Individual_Data_Resource . + ?record aocat:was_modified ?modified . + } + }; + +PREFIX aocat: +PREFIX skos: +PREFIX ariadneplus: + +INSERT { + GRAPH { + ?record aocat:was_issued ?coll_iss . + } +} +USING +USING +WHERE { + ?record rdf:type aocat:AO_Individual_Data_Resource . + ?record aocat:is_part_of ?coll . + ?coll aocat:was_issued ?coll_iss . + MINUS{ + ?record rdf:type aocat:AO_Individual_Data_Resource . + ?record aocat:was_issued ?issued . + } +}; + PREFIX skos: PREFIX aocat: INSERT {