Addressing ISSUE-47 (invalid and relative IRIs)

I've updated the R2RML spec with some text to address ISSUE-47
http://www.w3.org/2001/sw/rdb2rdf/track/issues/47

The question was: What happens if rr:column or rr:template produce invalid IRIs? Is it an error? Is the triple skipped? And what if they produce relative IRIs? Is that valid? How exactly are they turned into the absolute IRIs that are required by RDF and SPARQL?

The new text is here:
http://www.w3.org/2001/sw/rdb2rdf/r2rml/#generated-rdf-term
and here:
http://www.w3.org/2001/sw/rdb2rdf/r2rml/#from-template

The gist is:

1. Added a base IRI to the execution environment

2. Relative IRIs are made absolute by *concatenating* with the base IRI. Using the usual RFC 3986 relative IRI resolution algorithm is not good here because it would be hard to reverse it to get back the relative IRI from the absolute IRI. Reversing is necessary for SPARQL.

3. Invalid IRIs (e.g., anything containing spaces and so on) are skipped, and if any triple would include such an IRI then that triple is skipped

4. rr:template is changed so that it %-encodes most characters. This means that rr:column "person/{NAME}" will work even if the name contains spaces, the result will be "http://base.uri/person/Alice%20Smith"

Hope this works. I've set the issue to "Pending Review".

I also set ISSUE-38 to "Pending Review". This one was about the question whether the execution environment should contain more stuff besides the SQL connection. Now it also has the base IRI, and I can't think of anything else that should be in there, so I consider ISSUE-38 addressed.

Best,
Richard

Received on Monday, 4 July 2011 23:15:11 UTC