SPARQL Queries
SPARQL is a W3C query language standard to retrieve and manipulate data stored in Resource Description Framework (RDF) format, thus including OWL ontologies.
The use of SPARQL queries asks for a SPARQL Endpoint, i.e. a server that can handle HTTP requests. SPARQL Endpoints are typically provided by RDF stores.
This section presents examples of SPARQL Queries tailored for the Factory Data Model. These examples must be intended as templates that can be customized by specifying RDF Datasets.
The full set of SPARQL queries is available in this folder.

Get Part Types

1
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
2
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
3
PREFIX factory: <http://www.ontoeng.com/factory#>
4
select distinct ?parttype
5
WHERE {
6
?parttype rdf:type/rdfs:subClassOf* factory:ArtifactType .
7
}
Copied!

Get Process Plans

1
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
2
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
3
PREFIX ifc: <http://ifcowl.openbimstandards.org/IFC4_ADD1#>
4
PREFIX ifcext: <http://www.ontoeng.com/IFC4_ADD1_extension#>
5
PREFIX factory: <http://www.ontoeng.com/factory#>
6
select distinct ?parttype ?pplan
7
WHERE {
8
?parttype rdf:type/rdfs:subClassOf* factory:ArtifactType .
9
?pplan rdf:type/rdfs:subClassOf* ifc:IfcTaskType .
10
?parttype ifcext:hasAssignedObject|^ifcext:hasAssignmentTo ?pplan .
11
}
Copied!
Last modified 6d ago