TracNav menu
-
RDS/WIP project
- RDS/WIP Introduction
-
RDS/WIP World View...
- RDS/WIP Sample Queries
- RDS/WIP Staging Diagrams
- RDS/WIP 1.0 Plan
- RDS/WIP 1.0 Testing
- RDS/WIP 1.0 Process
- RDS/WIP 1.0 Inventory
- RDS/WIP 2.0 Plan
- RDS/WIP ID Generator
- RDS/WIP Domain Proposal
- RDS/WIP Requirements Table
- RDS/WIP Use Case: Discrete Editing
- RDS/WIP Use Case: CSV Upload
- RDS/WIP 1.0 General Use Cases
- RDS/WIP 2.0 General Use Cases
- RDS/WIP ISO 15926 Template Definitions
- RDS/WIP OWL/RDF Definition
- RDS/WIP OWL/RDF Project Plan
- RDS/WIP Forums
-
External
- RDS/WIP Use Case: Bulk Upload
POSC-Caesar FIATECH IDS-ADI Projects
Intelligent Data Sets Accelerating Deployment of ISO15926
Realizing Open Information Interoperability
RDS/WIP sample queries in SPARQL
Contents
Using the OWL/RDF native endpoint
The triplestores that hold the OWL/RDF content of the RDS/WIP have protocol endpoints conforming to the SPARQL Protocol Recommendation from the W3C. To query it using SPARQL clients, just enter the service URI of the endpoint you're interested in, for example: http://rdl.rdlfacade.org/data is the URI of the endpoint containing classifications outside of the base part 2 data model.
(@todo consider use of word base here versus core)
Using the PCA RDL endpoint
To execute the following scripts, go to the PCA RDL SPARQL query page.
These scripts are currently demonstrated against the PCA RDL endpoint, which represents ISO 15926 definitions in a form closely related to the evolving RDS/WIP form - they give some idea of the possibilities when using SPARQL with ISO 15926.
Taxonomy
1. Get me all the subclasses of PUMP, in a table
If you wish to see what this returns right away, just click here to submit the query to the RDS/WIP.
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 xsd: <http://www.w3.org/2001/XMLSchema#> PREFIX dm: <http://dm.rdlfacade.org/data#> PREFIX dc: <http://purl.org/dc/elements/1.1/> PREFIX rdl: <http://rds.posccaesar.org/2008/06/OWL/RDL#> PREFIX base: <http://rdl.rdlfacade.org/data> SELECT ?subclassIdPCA ?subclassDesignation ?superclassIdPCA ?superclassDesignation WHERE { ?specialization dm:hasSuperclass ?superclass . ?specialization dm:hasSubclass ?subclass . ?subclass rdl:hasIdPCA ?subclassIdPCA . ?subclass rdl:hasDesignation ?subclassDesignation . ?superclass rdl:hasIdPCA ?superclassIdPCA . ?superclass rdl:hasDesignation ?superclassDesignation . ?superclass rdl:hasDesignation "PUMP" } LIMIT 100
2. Get me all subclasses of PUMP, in a typical OWL format
The following query serves to extract a (tiny) subset of the Reference Data Library, returning RDF data with rdfs:label applied for the names of the reference entitites. To see the output right away, click here. If you save the resulting page from your browser to a file, say pumps.owl, you can load it in an OWL application, such as the on-line OwlSight or the Protégé editor.
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 xsd: <http://www.w3.org/2001/XMLSchema#> PREFIX dm: <http://dm.rdlfacade.org/data#> PREFIX dc: <http://purl.org/dc/elements/1.1/> PREFIX rdl: <http://rds.posccaesar.org/2008/06/OWL/RDL#> PREFIX base: <http://rdl.rdlfacade.org/data> CONSTRUCT { rdl:RDL_Fragment_Test a owl:Ontology . ?subclass a owl:Class . ?superclass a owl:Class . ?subclass rdfs:subClassOf ?superclass . ?subclass rdfs:label ?subclassDesignation . ?superclass rdfs:label ?superclassDesignation . } WHERE { ?specialization dm:hasSuperclass ?superclass . ?specialization dm:hasSubclass ?subclass . ?subclass rdl:hasIdPCA ?subclassIdPCA . ?subclass rdl:hasDesignation ?subclassDesignation . ?superclass rdl:hasIdPCA ?superclassIdPCA . ?superclass rdl:hasDesignation ?superclassDesignation . ?superclass rdl:hasDesignation "PUMP" } limit 100