This topic contains the following.
Changes in Oracle Database Release 18.1
The following are changes in Oracle Spatial and Graph RDF Semantic Graph Developer's Guide for Oracle Database Release 18.1.
Support Added for Oracle Database In-Memory
RDF data can easily be loaded into memory to take advantage of the Oracle Database In-Memory feature. A semantic network can now be loaded into memory with the SEM_APIS.ENABLE_INMEMORY procedure. In addition, in-memory virtual columns can be used at the virtual model level to add lexical values for RDF terms to the in-memory representation of the MDSYS.RDF_LINK$ table, thus reducing the number of joins required to evaluate SPARQL queries.
For more information, see RDF Support for Oracle Database In-Memory.
Support Added for Semantic Networks with Composite Partitioning
Semantic networks can now be created with list-hash composite partitioning. With this scheme, a semantic network is initially list-partitioned by model id, and then each partition is subpartitioned using a hash of the RDF predicate ID. Composite partitioning improves SPARQL query performance through increased parallelization and better query optimizer statistics.
For more information, see Semantic Network.
Enhanced CLOB Support for Bulk Load Operations
Staging tables that contain RDF quads with long literals (RDF object values greater than 4000 bytes in size) can now be efficiently loaded with SEM_APIS.BULK_LOAD_FROM_STAGING_TABLE.
New options have also been added to SEM_APIS.LOAD_INTO_STAGING_TABLE for better handling of long literals when loading from an external table. The
VC_ONLY option loads only RDF quads with object values not larger than 4000 bytes into a staging table, and the
CLOB_ONLY option loads only RDF quads with object values larger than 4000 bytes. These options allow a very efficient two-phase bulk load where VARCHAR-only data is loaded in one bulk load operation and CLOB-only data is loaded in a second bulk load operation.
Native Support for Turtle and Trig RDF Formats
Turtle and Trig RDF formats can now be directly loaded into Oracle Database without the need for third-party tools. SPARQL LOAD operations executed through SEM_APIS.UPDATE_MODEL can now parse and insert RDF data serialized in Turtle and Trig formats in addition to the N-Triple and N-Quad formats that were previously supported.
RDF Views can now be created directly from R2RML mappings specified in Turtle or N-Triple format. New R2RML_STRING and R2RML_STRING_FMT arguments have been added to SEM_APIS.CREATE_RDFVIEW_MODEL so that an R2RML mapping string can be used to create an RDF View model.
Support for RDF Added to SQL Developer
You can use Oracle SQL Developer to create RDF-related objects and use RDF and OWL features.
For more information, see RDF Support in SQL Developer.
Changes in Oracle Database 12c Release 2 (12.2)
The following are changes in Oracle Spatial and Graph RDF Semantic Graph Developer's Guide for Oracle Database 12c Release 2 (12.2).
Required: Migrate Existing Semantic Data
If you have any semantic data created using Oracle Database 11.1. 11.2, or 12.1, then before you use it in an Oracle Database 12.2 environment, you must migrate this data.
For an explanation, see Required Migration of Pre-12.2 Semantic Data.
SPARQL Update Operations on a Semantic Model
You can now perform SPARQL Update operations on a semantic model. The W3C SPARQL 1.1 Update is supported in Oracle Database semantic technologies through the new SEM_APIS.UPDATE_MODEL procedure.
For more information, see Support for SPARQL Update Operations on a Semantic Model.
RDF ORDER BY Query Enhancement and Option
Queries on RDF data that use SPARQL ORDER BY semantics are by default now processed more efficiently than in previous releases. This internal efficiency involves the use of the ORDER_TYPE, ORDER_NUM, and ORDER_DATE columns in the MDSYS.RDF_VALUE$ metadata table (documented in Statements). However, if for any reason you want to disable this feature, you can do so by specifying the
DISABLE_ORDER_COL option in the SEM_MATCH query.
For an explanation, see Enhanced RDF ORDER BY Query Processing.
Integration with Property Graph Data Stored in Oracle Database
Property graph data stored in Oracle Database can be integrated with RDF data through the use of RDF views. A convenient PL/SQL API is provided for creating and maintaining RDF views of property graph data. RDF views of property graphs behave the same way as RDF views of relational data and can be queried with SPARQL or materialized as native RDF data.
For more information, see RDF Integration with Property Graph Data Stored in Oracle Database.
A new SPARQL_TO_SQL PL/SQL procedure has been added to the SEM_APIS package. This procedure allows you to obtain the SQL translation of a SPARQL query. The resulting SQL string can be executed just like any other SQL string (for example, using JDBC from Java or using EXECUTE IMMEDIATE from PL/SQL). In addition, SPARQL_TO_SQL supports read only databases, long SPARQL query strings, and JDBC and PL/SQL bind variables.
For more information, see Using the SEM_APIS.SPARQL_TO_SQL Function to Query Semantic Data.
New SPARQL Query Functions
New Oracle-specific SPARQL query functions are available:
orardf:like(RDF term, pattern)
orardf:sameCanonTerm(RDF term, RDF term)
For information, see the table of Oracle-Specific Query Functions in Graph Patterns: Support for Curly Brace Syntax, and OPTIONAL, FILTER, UNION, and GRAPH Keywords.
Enhanced GeoSPARQL Support
GeoSPARQL support has been enhanced for increased functionality and performance.
Support for standard EPSG SRID URIs,
ogc:gmlLiteralgeometry serialization, and 3-dimensional geometries has been added.
Query performance has increased up to 10 times by adding a materialized SDO_GEOMETRY column to MDSYS.RDF_VALUE$.
Support for Flashback Query
Oracle Flashback Query is now supported for RDF data. You can use SEM_MATCH or SEM_APIS.SPARQL_TO_SQL to query an RDF model as it existed at an earlier time through an AS_OF hint that specifies a target system change number (SCN) or timestamp.
For more information, see Flashback Query Support.
Desupport for Workspace Manager and Virtual Private Database with RDF
Workspace Manager Support for RDF Data and Virtual Private Database Support in RDF Semantic Graph are desupported in Oracle Database 12c Release 2 (12.2). Information about such support has been removed from this guide.
If you have an existing semantic network that contains Workspace Manager (WM) or Virtual Private Database (VPD) data, see Workspace Manager and Virtual Private Database Desupport before you upgrade,
Changes in Oracle Database 12c Release 1 (188.8.131.52)
The following are changes in Oracle Spatial and Graph RDF Semantic Graph Developer's Guide for Oracle Database 12c Release 1 (184.108.40.206).
Support for SPARQL 1.1 Federated Query
SEM_MATCH supports SPARQL 1.1 Federated Query. The SERVICE construct can be used to retrieve results from a specified SPARQL endpoint URL. With this capability, you can combine local RDF data (native RDF data or RDF views of relational data) with other, possibly remote, RDF data served by a W3C standards-compliant SPARQL endpoint.
For information about support for SPARQL 1.1 Federated Query, see Graph Patterns: Support for SPARQL 1.1 Federated Query.
Combining Native Triple Data with Virtual RDB2RDF Triple Data
A new section (Combining Native RDF Data with Virtual RDB2RDF Data) explains how you can combine native triple data with virtual RDB2RDF triple data in a single SEM_MATCH query by means of the SERVICE keyword.
Changes in Oracle Database 12c Release 1 (220.127.116.11)
The following are changes in Oracle Spatial and Graph RDF Semantic Graph Developer's Guide for Oracle Database 12c Release 1 (18.104.22.168).
The following features are new in this release.
Enhanced Support for SPARQL 1.1 Constructs
SEM_MATCH supports the following SPARQL 1.1 constructs, as explained in Graph Patterns: Support for SPARQL 1.1 Constructs:
Enhanced Support for Virtual Models
Virtual models can now be created with arbitrary combinations of models and/or entailments, as explained in Virtual Models. Previously, virtual models were required to have at least one model and were limited to at most one entailment.
Virtual models can now be replaced without first being dropped. A new
REPLACE=T option for the SEM_APIS.CREATE_VIRTUAL_MODEL procedure lets you maintain access privileges for a virtual model while changing its definition. (The
REPLACE=T option is analogous to using CREATE OR REPLACE VIEW with a view.)
Support for User-Defined Inferencing and Querying
New RDF Semantic Graph extension architectures enable the addition of user-defined capabilities:
The inference extension architecture enables you to add user-defined inferencing to the presupplied inferencing support.
The query extension architecture enables you to add user-defined functions and aggregates to be used in SPARQL queries, both through the SEM_MATCH table function and through the support for Apache Jena.
For information about these features, see User-Defined Inferencing and Querying .
OWL 2 EL Support
The OWL 2 EL profile is supported by the addition of the system-defined rulebase
OWL2EL, as explained in Supported OWL Subsets.
OGC GeoSPARQL Support
The OGC GeoSPARQL standard for representing and querying spatial data is now supported, as explained in OGC GeoSPARQL Support.
Ladder-based inference is available as a convenient option for fine-grained triple-level security, as explained in Fine-Grained Security for Inferred Data and Ladder-Based Inference (LBI).
You can create and use RDF views over relational data. Mapping relational data to RDF triples enables you to perform semantic operations conveniently, and without having to store RDF triples corresponding to the relational data. For information, see RDF Views: Relational Data as RDF .
Data Pump Support for Exporting and Importing a Semantic Network
Effective with Oracle Database Release 12.1, you can export and import a semantic network using the full database export and import features of the Oracle Data Pump utility, as explained in Exporting or Importing a Semantic Network Using Oracle Data Pump.
Support for the following in RDF Semantic Graph is deprecated in this release, and may be desupported in a future release:
Virtual Private Database (VPD)
Version-enabled (Workspace Manager) models
Some features previously described in this document are desupported in Oracle Database 12c Release 1 (12.1). See Oracle Database Upgrade Guide for a list of desupported features.
Changes for RDF Semantic Graph Support for Apache Jena
RDF Semantic Graph support for Apache Jena supports Apache Jena 2.11.1, including jena-core-2.11.1 and jena-arq-2.11.1. This support includes the following features (most of which were included when support was added for Apache Jena 2.7.2).
For information about using the support for Apache Jena, see RDF Semantic Graph Support for Apache Jena .
Support for Retrieving User-Friendly Java Objects from SEM_MATCH or SQL-Based Query Results
With support for retrieving user-friendly Java objects from SEM_MATCH or SQL-based graph query results, you no longer need to parse and understand the subtle details embedded in projected columns like $RDFVTYP, $RDFLTYP, $RDFLANG, and $RDFCLOB; or their corresponding columns in MDSYS.RDF_VALUE$ including VALUE_TYPE, LITERAL_TYPE, LANGUAGE_TYPE, LONG_VALUE, and VALUE_NAME.
For an explanation and examples, see Retrieving User-Friendly Java Objects from SEM_MATCH or SQL-Based Query Results.
Protege Plugin for Oracle Database
This plugin allows an easy integration of the Protege 4.1 visual ontology editing functions with the robust semantic data management capabilities provided by Oracle Database.
The plugin .jar file and installation document are under the
protege_plugin/ directory of the release zip file.
Support for Customized Data Source Name
In previous releases, a fixed data source name OracleSemDS was required in the Joseki deployment. This release allows you to customize the data source name through the
oracle:dataSourceName setting in the Joseki configuration.
You can also customize the data source name used for establishing database connections to terminate long-running SPARQL queries using query ID (see Terminating Long-Running SPARQL Queries for details). To change the default data source name, edit the following JVM property:
Support for SPARQL Queries with Translated SQL Text Larger Than 29000 Bytes
The S2S feature has been enhanced such that it now supports very long SPARQL queries that have translated SQL texts that are hundreds of thousands of bytes long. However, Oracle still recommends the use of simpler (and shorter) SPARQL queries whenever possible, because simpler SPARQL queries are easier for users and application developers to understand, and they tend to be more efficient for Oracle Database to execute.
Support for Oracle Database in Read-Only Mode
The Joseki web service endpoint can now work with an Oracle Database opened in read-only mode. Queries can be answered without problems.
S2S must be used for queries to work with a read-only Oracle Database.
Less Verbose Joseki Output
This release reduces the amount of Joseki logging output. You can, however, set the trace level to 1 or higher to get more trace output for debugging purpose. For example:
Java APIs for Managing the Table Responsible for Terminating Long-Running SPARQL Queries
When a request to terminate a SPARQL query is sent using the following servlet:
the request (query ID and a timestamp) is recorded in a table named ORACLE_ORARDF_QUERY_MGT_TAB in user's schema.
The following methods have been added to the class
oracle.spatial.rdf.client.jena.OracleQueryProgressMonitor to allow users to query, add, and remove entries in the ORACLE_ORARDF_QUERY_MGT_TAB table. Details of these methods are explained in the Javadoc (
javadoc.zip is under the
javadoc/ directory of the release zip file):
addQuery deleteAllQueries deleteQuery listQueries
Support for Apache Tomcat and JBoss Application Server
Support is provided for Joseki deployment in Apache Tomcat and JBoss, in addition to Oracle WebLogic Server. For information, see Deploying Joseki in Apache Tomcat or JBoss.
Support for Fuseki 1.0.1
Support is provided for using Fuseki 1.0.1 to serve RDF data over HTTP.
For information, see Configuring the Fuseki-Based SPARQL Service.