Skip to content
Nikolaos Konstantinou edited this page Sep 3, 2018 · 18 revisions

Using the binary

  1. Dowload and extract the latest release of the R2RML Parser tool.

  2. Modify the properties file (r2rml.properties by default, but you can define your properties using the -p command line option, e.g. ./r2rml-parser.sh -p my.properties). Here you can configure almost anything, without altering the source code. The most important properties are the following:

    mapping.file: The R2RML mapping file that defines how the mappings will be materialized. Make sure you provide valid SQL queries and respect R2RML syntax.

    source database connection properties ( db.url, db.login, db.password, db.driver ).

    In case of exporting as an RDF file on the hard disk:jena.destinationFileName: The file that will contain the output in RDF, based on the mapping file and the source database.

    jena.storeOutputModelUsingTdb: Has to be set to true when the target model is serialized using Jena TDB.

    jena.tdb.directory: If property jena.storeOutputModelUsingTdb is set to true, this property defines the directory where the target model will be serialized

  3. Execute r2rml-parser.bat (r2rml-parser.sh in linux, do not forget to run chmod +x r2rml-parser.sh before execution).

Developing using the source code

  1. Install git (https://git-scm.com/). Optionally a git client with a GUI (e.g. https://desktop.github.com/ or any of the free available).

  2. Clone the repository locally (git clone https://github.com/nkons/r2rml-parser.git or git clone [email protected]:nkons/r2rml-parser.git).

  3. Install a Java JDK (a JDK, not a JRE, as it is needed by Maven to compile the code).

  4. Use an IDE. I would recommend Eclipse. It also has a git client. Conveniently, it also has an embedded Maven runtime.

  5. Import the project into Eclipse (File -> Import -> Existing Maven projects).

  6. From Eclipse, compile and run the project using mvn package: Right click on project head -> Run as -> Maven build... -> package (in the Goals textbox).

  7. Once this finishes, the folder "target" will contain your version of the tool, which you will be able to execute via the command line. Alternatively, you can run the project from within Eclipse by right clicking on Main.java -> Run as -> Java application.

See included example

In the iswc folder you will find: