diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql index a86dda1..cf6ea3d 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql +++ b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql @@ -1,70 +1,70 @@ -PREFIX aocat: -PREFIX rdfs: -PREFIX skos: -PREFIX aoprop: +PREFIX aocat: +PREFIX rdfs: +PREFIX skos: +PREFIX aoprop: PREFIX onto: PREFIX ariadneplus: PREFIX time: CONSTRUCT { - aoprop:rdfType "Record" . - aoprop:identifier . - aoprop:originalId ?originalId . - aoprop:issued ?issued . - aoprop:modified ?modified . - aoprop:partOf ?partOf . - aoprop:creator ?creator . +%record aoprop:rdfType "Record" . +%record aoprop:identifier %record . +%record aoprop:originalId ?originalId . +%record aoprop:issued ?issued . +%record aoprop:modified ?modified . +%record aoprop:partOf ?partOf . +%record aoprop:creator ?creator . ?creator aoprop:name ?creatorName . ?creator aoprop:email ?creatorEmail . - aoprop:contributor ?contributor . +%record aoprop:contributor ?contributor . ?contributor aoprop:name ?contributorName . ?contributor aoprop:email ?contributorEmail . - aoprop:legalResponsible ?legalResponsible . +%record aoprop:legalResponsible ?legalResponsible . ?legalResponsible aoprop:name ?legalResponsibleName . ?legalResponsible aoprop:email ?legalResponsibleEmail . - aoprop:owner ?owner . +%record aoprop:owner ?owner . ?owner aoprop:name ?ownerName . ?owner aoprop:email ?ownerEmail . - aoprop:publisher ?publisher . +%record aoprop:publisher ?publisher . ?publisher aoprop:name ?publisherName . ?publisher aoprop:email ?publisherEmail . - aoprop:accessPolicy ?accessPolicy . - aoprop:accessRights ?accessRights . - aoprop:landingPage ?landingPage . - aoprop:spatialRegion ?spatialRegion . +%record aoprop:accessPolicy ?accessPolicy . +%record aoprop:accessRights ?accessRights . +%record aoprop:landingPage ?landingPage . +%record aoprop:spatialRegion ?spatialRegion . ?spatialRegion aoprop:placeName ?spatialPlaceName . ?spatialRegion aoprop:spatialCoordinateSystem ?spatialCoordinateSystem . - aoprop:spatialRegionPoint ?spatialRegionPoint . +%record aoprop:spatialRegionPoint ?spatialRegionPoint . ?spatialRegionPoint aoprop:lat ?spatialLocationLat . ?spatialRegionPoint aoprop:lon ?spatialLocationLon . - aoprop:spatialRegionBox ?spatialRegionBox . +%record aoprop:spatialRegionBox ?spatialRegionBox . ?spatialRegionBox aoprop:boxMaxLat ?spatialLocationBBMaxLat . ?spatialRegionBox aoprop:boxMaxLon ?spatialLocationBBMaxLon . ?spatialRegionBox aoprop:boxMinLat ?spatialLocationBBMinLat . ?spatialRegionBox aoprop:boxMinLon ?spatialLocationBBMinLon . - aoprop:uri ?temporal . +%record aoprop:uri ?temporal . ?temporal aoprop:periodName ?temporalPeriodName . ?temporal aoprop:from ?temporalFrom . ?temporal aoprop:until ?temporalUntil . ?temporal aoprop:uri ?temporal . - aoprop:uri ?temporalNative . +%record aoprop:uri ?temporalNative . ?temporalNative aoprop:periodName ?temporalNativePeriodName . - aoprop:archeologicalResourceType ?archeologicalResourceType . +%record aoprop:archeologicalResourceType ?archeologicalResourceType . ?archeologicalResourceType aoprop:name ?archeologicalResourceTypeName . - aoprop:resourceType ?resourceType . - aoprop:nativeSubject ?nativeSubject . +%record aoprop:resourceType ?resourceType . +%record aoprop:nativeSubject ?nativeSubject . ?nativeSubject aoprop:prefLabel ?nativeSubjectPrefLabel . ?nativeSubject aoprop:rdfAbout ?nativeSubject . - aoprop:derivedSubject ?derivedSubject . +%record aoprop:derivedSubject ?derivedSubject . ?derivedSubject aoprop:prefLabel ?derivedSubjectPrefLabel . ?derivedSubject aoprop:source "Getty AAT" . - aoprop:aatSubjects ?derivedSubject . +%record aoprop:aatSubjects ?derivedSubject . ?derivedSubject aoprop:id ?derivedSubject . ?derivedSubject aoprop:label ?derivedSubjectPrefLabel . ?derivedSubject aoprop:lang ?aatSubjectsLang . - aoprop:title ?title . - aoprop:description ?description . - aoprop:language ?language . +%record aoprop:title ?title . +%record aoprop:description ?description . +%record aoprop:language ?language . } from from @@ -72,37 +72,37 @@ from from from where { - aocat:has_language / skos:prefLabel ?language . - aocat:has_original_id ?originalId . - aocat:is_part_of ?partOf . - aocat:has_creator ?creator . + %record aocat:has_language / skos:prefLabel ?language . + %record aocat:has_original_id ?originalId . + %record aocat:is_part_of ?partOf . + %record aocat:has_creator ?creator . ?creator aocat:has_name ?creatorName . - aocat:has_title ?title . - aocat:has_type / skos:prefLabel ?resourceType . - aocat:has_native_subject ?nativeSubject . + %record aocat:has_title ?title . + %record aocat:has_type / skos:prefLabel ?resourceType . + %record aocat:has_native_subject ?nativeSubject . ?nativeSubject skos:prefLabel ?nativeSubjectPrefLabel . optional { - aocat:has_derived_subject ?derivedSubject . + %record aocat:has_derived_subject ?derivedSubject . ?derivedSubject skos:prefLabel ?derivedSubjectPrefLabel . } optional { ?creator aocat:has_email ?creatorEmail . } optional { - aocat:has_description ?description . + %record aocat:has_description ?description . } optional { - aocat:has_access_policy / rdfs:label ?accessPolicy . + %record aocat:has_access_policy / rdfs:label ?accessPolicy . } optional { - aocat:has_landing_page / rdfs:label ?landingPage . + %record aocat:has_landing_page / rdfs:label ?landingPage . } optional { - aocat:has_temporal_coverage ?temporalNative . + %record aocat:has_temporal_coverage ?temporalNative . ?temporalNative aocat:has_native_period / skos:prefLabel ?temporalNativePeriodName . } optional { - aocat:has_temporal_coverage ?temporal . + %record aocat:has_temporal_coverage ?temporal . ?temporal aocat:has_period / skos:prefLabel ?temporalPeriodName . optional { ?temporal aocat:from ?temporalFrom . @@ -113,18 +113,18 @@ where { { select * where { - aocat:was_issued ?issued . - aocat:was_modified ?modified . - aocat:has_contributor ?contributor . + %record aocat:was_issued ?issued . + %record aocat:was_modified ?modified . + %record aocat:has_contributor ?contributor . ?contributor aocat:has_name ?contributorName . - aocat:has_responsible ?legalResponsible . + %record aocat:has_responsible ?legalResponsible . ?legalResponsible aocat:has_name ?legalResponsibleName . - aocat:has_owner ?owner . + %record aocat:has_owner ?owner . ?owner aocat:has_name ?ownerName . - aocat:has_publisher ?publisher . + %record aocat:has_publisher ?publisher . ?publisher aocat:has_name ?publisherName . - aocat:has_access_rights ?accessRights . - aocat:has_ARIADNE_subject ?archeologicalResourceType . + %record aocat:has_access_rights ?accessRights . + %record aocat:has_ARIADNE_subject ?archeologicalResourceType . ?archeologicalResourceType skos:prefLabel ?archeologicalResourceTypeName . optional { ?contributor aocat:has_email ?contributorEmail . @@ -144,24 +144,24 @@ where { { select * where { - aocat:has_spatial_coverage ?spatialRegion . + %record aocat:has_spatial_coverage ?spatialRegion . ?spatialRegion aocat:has_place_name ?spatialPlaceName . optional { ?spatialRegion aocat:has_coordinate_system ?spatialCoordinateSystem . } optional { - aocat:has_spatial_coverage ?spatialRegionPoint . + %record aocat:has_spatial_coverage ?spatialRegionPoint . ?spatialRegionPoint aocat:has_latitude ?spatialLocationLat ; aocat:has_longitude ?spatialLocationLon . } optional { - aocat:has_spatial_coverage ?spatialRegionBox . - ?spatialRegionBox aocat:has_bounding_box_max_lat ?spatialLocationBBMaxLat ; + %record aocat:has_spatial_coverage ?spatialRegionBox . + ?spatialRegionBox aocat:has_bounding_box_max_lat ?spatialLocationBBMaxLat ; aocat:has_bounding_box_max_lon ?spatialLocationBBMaxLon ; aocat:has_bounding_box_min_lat ?spatialLocationBBMinLat ; aocat:has_bounding_box_min_lon ?spatialLocationBBMinLon ; } - } + } } BIND (lang(?derivedSubjectPrefLabel) as ?aatSubjectsLang) } \ No newline at end of file