Skip to content

conversion:range_template

Tim L edited this page Jun 6, 2013 · 11 revisions
csv2rdf4lod-automation is licensed under the [Apache License, Version 2.0](https://github.com/timrdf/csv2rdf4lod-automation/wiki/License)

What is first

What we will cover

This page describes how the conversion:range_template enhancement changes the URI of a triple's object when converting a tabular cell's value.

Let's get to it

conversion:range_template behaves just like conversion:domain_template, but affects the URI naming of the object created from a cell value, instead of naming the subject of the triple.

Enhancement pattern: De-scoping

When converting multiple files, conversion:subject_discriminator becomes part of the URIs created when promoting cell values to rdfs:Resources. This is to avoid naming "collisions" in cases where the different files mention the same string but are not referring to the same thing. However, in many cases, you will want to align the URIs for objects created from cells of different files.

If you want to merge according to the new URIs' type (the more common case) (change typed/country to typed/<whatever your class is>):

     conversion:enhance [
        ov:csvCol          3;
        ov:csvHeader       "Country Code";
        conversion:label   "country";
        conversion:comment "";
        conversion:range_template "[/sd]typed/country/[.]";
        conversion:range   rdfs:Resource;
        conversion:range_name   "Country";

If you want to merge according to the predicates referring the new URIs:

todo

What is next

Clone this wiki locally