Step-by-step guide to importing RDF data

This guide is for importing larger amounts of data (e.g. more than a few thousand RDF triples) asynchronously. For smaller data, it is simpler to add data synchronously.

An RDF import has these components:

RDF file
The file containing the RDF data (can be in any RDF syntax)
Transformation query (optional)
SPARQL CONSTRUCT query that maps RDF to another RDF representation
Graph (optional)
The document that the import results will be stored in, if no transformation query is specified
RDF import
Combines the file with the corresponding query

Specify either a query or a graph, but not both.

Import an RDF file

Without a transformation, the import asynchronously appends the RDF data to a document (see how to create a document). With a transformation, it runs the uploaded RDF through a CONSTRUCT query before storing it, so the import can restructure or re-route the data.

All the import components can be created from a single dialog, but the steps below create them one at a time:

  1. First, create a container for the data to be imported. This will be the import's target container.
  2. Upload an RDF file. Click on the Create dropdown at the bottom of the page and select File. This will open a new form.
  3. Fill out the Item fields — the document's Title (required) and optional Description, the same fields used when creating a document.
  4. Fill out the mandatory File fields:
    Filename
    Click on Choose file and select an RDF file from your computer
    Title
    File title
  5. Once all the fields have been filled in, click Save.
  6. The browser will open your uploaded file.
  7. If you are importing with a transformation, create a transformation query that will transform the uploaded RDF to a new RDF structure. Click on the Create dropdown at the bottom of the page and select CONSTRUCT. This will open a new form. Fill out the Item fields and the mandatory CONSTRUCT fields:
    Text
    SPARQL CONSTRUCT query string
    You will not be able to save the query if its syntax is not valid SPARQL 1.1.
    Title
    Query title
    Once all the fields have been filled in, click Save. You can find the query saved in the Queries container, which you can open from the document tree in the left sidebar.
  8. Click on the Create dropdown button at the bottom of the page and select RDF Import. This will open a new form.
  9. Fill out the Item fields.
  10. Fill out the mandatory RDF Import fields:
    File
    Start typing the name of your RDF file and select it from the typeahead
    Title
    Import title
  11. Select either the target graph or the transformation query — but not both:
    Name
    Select the target graph (document) using the typeahead
    Query
    Select the transformation query using the typeahead
  12. Click Save and you will be redirected to the newly created import document.
  13. Reload the document after a few moments to see the import progress. On success, the amount of data imported is displayed; on failure, the constraint violations or other import errors.
  14. Go back to the target document to see the newly imported data items.

Read more about how RDF imports work.