Virtuoso Open-Source Wiki
Virtuoso Open-Source, OpenLink Data Spaces, and OpenLink Ajax Toolkit
Advanced Search
Help?
Location: / Dashboard / Main / VOSSQL2RDF

Mapping SQL Data to RDF

Introduction

Virtuoso uses a SPARQL-based Meta Schema Language to provide RDBMS-to-RDF mapping functionality (also described as, RDF Views of SQL data). The language is an extension of the SPARQL query language meshed with Virtuoso's SPASQL (SPARQL-inside-SQL) functionality. The language enables you to declaratively map relational database schema tables, columns, rows, and foreign key relationships to Classes, Attributes, Relationships, and Instances (Objects/Entities/Individuals) defined by RDF Schemas or OWL Ontologies. The mapping process uses a special built-in Virtuoso function to generate IRIs / URIs in "Subject" or "Object" position of a SPARQL graph pattern, en route to building a set of SQL compiler rules and optimizations for translating SPARQL queries into SQL on the fly.

Mapping Process

The basic steps are as follows:

  1. Identify the tables, views, and procedure views to be mapped.
  2. Decide if you are performing a 1:1 mapping or a more customized mapping to a specific RDF Schema or Ontology.
  3. Declare Virtuoso-URI-Generator functions for each Class in the target RDF Schema or Ontology.
  4. Use the Virtuoso-URI-Generator functions in SPARQL graph patterns within the ALTER QUAD STORAGE part of a SPASQL-based mapping statement.
  5. Use Virtuoso's built-in URL-Rewrite Rules APIs (or Conductor UI) to publish the Linked Data URIs which result from the mapping above.

Mapping Example

  • View an example of mapping the phpBB3 SQL schema to the classes defined by the SIOC and FOAF ontologies.

Linking Remote tables into Virtuoso Examples

  • View how to perform linking across all Virtuoso supported mechanisms i.e. for Oracle, SQL Server, DB2, Sybase, Informix, Ingres, MySQL, PostgreSQL, ODBC, and JDBC DSNs.

White Papers & Tutorials

Generation of RDF Views from SQL data

Automated Generation of RDF Views over Relational Data Sources

Sample Mapping Scripts

Web 2.0 Platforms

Semi-Structured Content Examples

Enterprise Data Access & Integration

ODS Applications RDF Views

Business Intelligence

How Do I ...?

Screencast Demos

Powered By Virtuoso