David Price

Work ERH Fact simple ontology

# baseURI: null
@prefix composite: <http://www.topbraid.org/2007/05/composite.owl#> .
@prefix forms: <http://www.topbraid.org/2007/01/forms.owl#> .
@prefix inference: <http://www.topbraid.org/2007/06/inference.owl#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix visual: <http://topbraid.org/visual#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
<http://www.reportinghub.no/erhf/schema/erh-facts#Field>
forms:keyProperties (rdfs:label rdfs:comment <http://www.reportinghub.no/erhf/schema/erh-facts#npdname>) .
# baseURI: http://www.reportinghub.no/erhf/schema/1.0/erh-facts
@prefix erhf: <http://www.reportinghub.no/erhf/schema/erh-facts#> .
@prefix npd: <http://www.reportinghub.no/np/schema/npd#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
......@@ -479,3 +480,10 @@ erhf:wellborePartOfWell
rdfs:domain erhf:Wellbore ;
rdfs:label "wellbore part of well"^^xsd:string ;
rdfs:range erhf:Well .
npd:fieldOperator
rdf:type owl:ObjectProperty .
npd:name
rdf:type owl:DatatypeProperty ;
rdfs:range xsd:string .
......
......@@ -29,7 +29,7 @@
] [ sp:object
[ sp:varName "npdname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
]) ;
sp:where ([ rdf:type sp:NotExists ;
......@@ -68,46 +68,12 @@
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "operator"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#operatingCompany> ;
sp:subject spin:_this
] [ sp:object <http://www.reportinghub.no/erhf/schema/erh-facts#Company> ;
sp:predicate rdf:type ;
sp:subject
[ sp:varName "operator"^^xsd:string
]
] [ sp:object
[ sp:varName "operatorid"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdid> ;
sp:subject
[ sp:varName "operator"^^xsd:string
]
] [ sp:object
[ sp:varName "oplabel"^^xsd:string
] ;
sp:predicate rdfs:label ;
sp:subject
[ sp:varName "operator"^^xsd:string
]
] [ sp:object
[ sp:varName "operatorname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:subject
[ sp:varName "operator"^^xsd:string
]
] [ sp:object
[ sp:varName "status"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#currentActivityStatus> ;
sp:subject spin:_this
]) ;
sp:where ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Field> ;
sp:predicate rdf:type ;
sp:subject spin:_this
] [ sp:object
sp:where ([ sp:object
[ sp:varName "id"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
......@@ -118,42 +84,10 @@
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "operator"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#fieldOperator> ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "operatorid"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
sp:subject
[ sp:varName "operator"^^xsd:string
]
] [ sp:object
[ sp:varName "operatorname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject
[ sp:varName "operator"^^xsd:string
]
] [ sp:object
[ sp:varName "status"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#currentActivityStatus> ;
sp:subject spin:_this
] [ rdf:type sp:Bind ;
sp:expression
[ rdf:type fn:concat ;
sp:arg1 [ sp:varName "operatorname"^^xsd:string
] ;
sp:arg2 " (NPD Id " ;
sp:arg3 [ sp:varName "operatorid"^^xsd:string
] ;
sp:arg4 ")"
] ;
sp:variable
[ sp:varName "oplabel"^^xsd:string
]
])
] .
......@@ -167,7 +101,7 @@
] [ sp:object
[ sp:varName "npdname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "field"^^xsd:string
......@@ -203,7 +137,7 @@
] [ sp:object
[ sp:varName "npdname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
]) ;
sp:where ([ sp:object
......@@ -239,7 +173,7 @@
] [ sp:object
[ sp:varName "npdname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
]) ;
sp:where ([ sp:object
......@@ -272,6 +206,11 @@
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "npdname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
]) ;
sp:where ([ sp:object
[ sp:varName "npdid"^^xsd:string
......@@ -304,9 +243,9 @@
sp:predicate rdfs:label ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "operatorname"^^xsd:string
[ sp:varName "npdname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/erhf/schema/erh-facts#npdname> ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
]) ;
sp:where ([ sp:object
......@@ -315,7 +254,7 @@
sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
sp:subject spin:_this
] [ sp:object
[ sp:varName "name"^^xsd:string
[ sp:varName "npdname"^^xsd:string
] ;
sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
sp:subject spin:_this
......