This document is licensed under a Creative Commons Attribution 3.0 License.
This document defines the RML test cases to the determine the RML specification conformance of tools.
This document is draft of a potential specification. It has no official standing of any kind and does not represent the support or consensus of any standards organization.
This document defines the RML test cases, consisting of a collection of test case documents (input and expected output). The purpose of the test cases is to determine the conformance of tools that execute RML rules to the RML specification.
We describe the test cases semantically to increase their reusability and sharability. To this end, we created a semantic data model, with as main entity the test case (see figure below). For each test case, the following details are described: unique identifier, title, description, relevant aspect of the RML specification, data sources (optional), expected knowledge graph or error, and RML rules.
To provide the corresponding semantic descriptions,
the model uses mostly
the Evaluation and Report Language (EARL) 1.0 Schema,
the Test case manifest vocabulary,
the Test Metadata vocabulary, and
the Data Catalog Vocabulary.
A test case is annotated with the classes earl:TestCase
, test:TestCase
, and mf:ManifestEntry
.
The identifier, title, description, and
the specific aspect of the RML specification that is being tested
are added as datatype properties.
The files that are provided as input to the tools are linked to the test cases via test:informationResourceInput
and dcterms:hasPart
.
The file with the RML rules is also linked via rml-tc:rules
.
The objects of these properties are of the class dcat:Dataset
,
which in turn link to a dcat:Distribution
that includes a link to a file.
The expected output, whether that is a knowledge graph or an error, is linked via test:expectedResults
, mf:result
, and dcterms:hasPart
.
In the case of a knowledge graph, the object of these properties is a dcat:Dataset
, linked to a dcat:Distribution
, to describe the file containing the graph.
In the case of an error, we link to the expected error.
test-cases
.
Each test case is contained in a single folder, containing three types of files:
mapping.ttl
,
in the Turtle format.
output.nq
.
No file is provided if an error is expected that must halt the generation of the RDF.
Title: one table, one column, zero rows
Description: Tests if an empty table produces an empty RDF graph
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ] ; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
# empty database
Title: one table, one column, zero rows
Description: Tests if an empty table produces an empty RDF graph
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ] ; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
# empty database
Title: one table, one column, zero rows
Description: Tests if an empty table produces an empty RDF graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
# empty database
Title: one table, one column, zero rows
Description: Tests if an empty table produces an empty RDF graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
# empty database
Title: one table, one column, zero rows
Description: Tests if an empty table produces an empty RDF graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
# empty database
Title: one table, one column, zero rows
Description: Tests if an empty table produces an empty RDF graph
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ] ; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
# empty database
Title: One column mapping, subject URI generation by using rr:template
Description: Tests: (1) one column mapping; (2) subject URI generation by using rr:tmplate; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, subject URI generation by using rr:template
Description: Tests: (1) one column mapping; (2) subject URI generation by using rr:tmplate; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap <#NameSubjectMap> ; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#NameSubjectMap> rr:template "http://example.com/{Name}" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, subject URI generation by using rr:template
Description: Tests: (1) one column mapping; (2) subject URI generation by using rr:tmplate; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, subject URI generation by using rr:template
Description: Tests: (1) one column mapping; (2) subject URI generation by using rr:tmplate; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, subject URI generation by using rr:template
Description: Tests: (1) one column mapping; (2) subject URI generation by using rr:tmplate; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, subject URI generation by using rr:template
Description: Tests: (1) one column mapping; (2) subject URI generation by using rr:tmplate; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, generation of a BlankNode subject by using rr:termType
Description: Tests: (1) one column mapping; (2) generation of a BlankNode subject by using rr:termType; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
_:Venus <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, generation of a BlankNode subject by using rr:termType
Description: Tests: (1) one column mapping; (2) generation of a BlankNode subject by using rr:termType; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
_:Venus <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, generation of a BlankNode subject by using rr:termType
Description: Tests: (1) one column mapping; (2) generation of a BlankNode subject by using rr:termType; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT Name FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, generation of a BlankNode subject by using rr:termType
Description: Tests: (1) one column mapping; (2) generation of a BlankNode subject by using rr:termType; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT name FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, generation of a BlankNode subject by using rr:termType
Description: Tests: (1) one column mapping; (2) generation of a BlankNode subject by using rr:termType; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT Name FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: One column mapping, generation of a BlankNode subject by using rr:termType
Description: Tests: (1) one column mapping; (2) generation of a BlankNode subject by using rr:termType; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
_:Venus <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Two columns mapping, generation of a subject URI by the concatenation of two column values
Description: Tests: (1) two column mapping, no primary key; (2) subject URI generated by the concatenation of two column values; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/10/Venus> <http://example.com/id> "10" . <http://example.com/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Two columns mapping, generation of a subject URI by the concatenation of two column values
Description: Tests: (1) two column mapping, no primary key; (2) subject URI generated by the concatenation of two column values; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/10/Venus> <http://example.com/id> "10" . <http://example.com/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Two columns mapping, generation of a subject URI by the concatenation of two column values
Description: Tests: (1) two column mapping, no primary key; (2) subject URI generated by the concatenation of two column values; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Two columns mapping, generation of a subject URI by the concatenation of two column values
Description: Tests: (1) two column mapping, no primary key; (2) subject URI generated by the concatenation of two column values; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Two columns mapping, generation of a subject URI by the concatenation of two column values
Description: Tests: (1) two column mapping, no primary key; (2) subject URI generated by the concatenation of two column values; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Two columns mapping, generation of a subject URI by the concatenation of two column values
Description: Tests: (1) two column mapping, no primary key; (2) subject URI generated by the concatenation of two column values; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/10/Venus> <http://example.com/id> "10". <http://example.com/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Two columns mapping, generation of a BlankNode subject by using rr:template and rr:termType
Description: Tests: (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using rr:template; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "students{ID}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
_:students10 <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Two columns mapping, generation of a BlankNode subject by using rr:template and rr:termType
Description: Tests: (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using rr:template; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "students{ID}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
_:students10 <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Two columns mapping, generation of a BlankNode subject by using rr:template and rr:termType
Description: Tests: (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using rr:template; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "students{ID}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:students10 <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Two columns mapping, generation of a BlankNode subject by using rr:template and rr:termType
Description: Tests: (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using rr:template; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "students{ID}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:students10 <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Two columns mapping, generation of a BlankNode subject by using rr:template and rr:termType
Description: Tests: (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using rr:template; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "students{ID}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
_:students10 <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Two columns mapping, generation of a BlankNode subject by using rr:template and rr:termType
Description: Tests: (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using rr:template; (3) one column to one property
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "students{ID}"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
_:students10 <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Two columns mapping, an undefined SQL identifier / logical reference
Description: Tests the presence of an undefined SQL identifier / logical reference
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined SQL identifier / logical reference
Description: Tests the presence of an undefined SQL identifier / logical reference
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined SQL identifier / logical reference
Description: Tests the presence of an undefined SQL identifier / logical reference (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined SQL identifier / logical reference
Description: Tests the presence of an undefined SQL identifier / logical reference (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined SQL identifier / logical reference
Description: Tests the presence of an undefined SQL identifier / logical reference (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined SQL identifier / logical reference
Description: Tests the presence of an undefined SQL identifier / logical reference
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, generation of a BlankNode subject by using a SQL Query that concatenates two columns
Description: Tests (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using a SQL Query that concatenates two columns; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT CONCAT('Student', ID) AS StudentId, ID, Name FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "StudentId"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Student10 <http://xmlns.com/foaf/0.1/name> "Venus".
Title: Two columns mapping, generation of a BlankNode subject by using a SQL Query that concatenates two columns
Description: Tests (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using a SQL Query that concatenates two columns; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT ('Student' || ID) AS StudentId, ID, Name FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "studentid"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "org.postgresql.Driver"; # this is ignored d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Student10 <http://xmlns.com/foaf/0.1/name> "Venus".
Title: Two columns mapping, generation of a BlankNode subject by using a SQL Query that concatenates two columns
Description: Tests (1) two column mapping, no primary key; (2) generation of a BlankNode subject by using a SQL Query that concatenates two columns; (3) one column to one property (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT CONCAT('Student', ID) AS StudentId, ID, Name FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "StudentId"; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; # this is ignored d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
_:Student10 <http://xmlns.com/foaf/0.1/name> "Venus".
Title: Two columns mapping, an undefined rr:tableName
Description: Tests the presence of an undefined rr:tableName
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student2.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined rr:tableName
Description: Tests the presence of an undefined rr:tableName
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student2.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined rr:tableName
Description: Tests the presence of an undefined rr:tableName (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "\"Students\"" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined rr:tableName
Description: Tests the presence of an undefined rr:tableName (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "\"Students\"" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined rr:tableName
Description: Tests the presence of an undefined rr:tableName (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "\"Students\"" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, an undefined rr:tableName
Description: Tests the presence of an undefined rr:tableName
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student2.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, delimited identifiers referenced as regular identifiers
Description: Tests the presence of delimited identifiers referenced as regular identifiers. Within rr:template ID is ok, but Name is not (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, delimited identifiers referenced as regular identifiers
Description: Tests the presence of delimited identifiers referenced as regular identifiers. Within rr:template ID is ok, but Name is not (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, delimited identifiers referenced as regular identifiers
Description: Tests the presence of delimited identifiers referenced as regular identifiers. Within rr:template ID is ok, but Name is not (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, invalid SQL query
Description: Tests the presence of an invalid SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT kjnqsdjfbqsdjfmsdnfm FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, invalid SQL query
Description: Tests the presence of an invalid SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT kjnqsdjfbqsdjfmsdnfm FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, invalid SQL query
Description: Tests the presence of an invalid SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT kjnqsdjfbqsdjfmsdnfm FROM student"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, duplicate column name in SELECT
Description: Tests the presence of duplicate column names in the SELECT list of the SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT Name, Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, duplicate column name in SELECT
Description: Tests the presence of duplicate column names in the SELECT list of the SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT Name, Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, duplicate column name in SELECT
Description: Tests the presence of duplicate column names in the SELECT list of the SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT Name, Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Two columns mapping, SQL Version identifier
Description: Tests the presence of a SQL Version identifier (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rml:query "SELECT Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
Title: Two columns mapping, SQL Version identifier
Description: Tests the presence of a SQL Version identifier (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rml:query "SELECT Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
Title: Two columns mapping, SQL Version identifier
Description: Tests the presence of a SQL Version identifier (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rml:query "SELECT Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
Title: Two columns mapping, qualified column names
Description: Tests the presence of qualified column names in the SELECT list of the SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT NoColumnName, Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
Title: Two columns mapping, qualified column names
Description: Tests the presence of qualified column names in the SELECT list of the SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT NoColumnName, Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
Title: Two columns mapping, qualified column names
Description: Tests the presence of qualified column names in the SELECT list of the SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT NoColumnName, Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
Title: Three columns mapping, undefined SQL Version identifier
Description: Tests the presence of an undefined SQL Version identifier (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rml:query "SELECT FirstName, LastName FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Three columns mapping, undefined SQL Version identifier
Description: Tests the presence of an undefined SQL Version identifier (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rml:query "SELECT FirstName, LastName FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Three columns mapping, undefined SQL Version identifier
Description: Tests the presence of an undefined SQL Version identifier (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rml:query "SELECT FirstName, LastName FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Name}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "IDs" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Three columns mapping, concatenation of columns, by using a rr:sqlQuery to produce literal
Description: Tests: (1) three column mapping; and (2) concatenation of columns to produce literal, by using a rr:sqlQuery (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT ID, LastName, CONCAT(`FirstName`, '', `LastName`) as Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{LastName}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name"; rr:termType rr:Literal; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Williams> <http://xmlns.com/foaf/0.1/name> "VenusWilliams" .
Title: Three columns mapping, concatenation of columns, by using a rr:sqlQuery to produce literal
Description: Tests: (1) three column mapping; and (2) concatenation of columns to produce literal, by using a rr:sqlQuery (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT id, lastname, concat_ws(firstname, '', lastname) as name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{id}/{lastname}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "name"; rr:termType rr:Literal; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Williams> <http://xmlns.com/foaf/0.1/name> "VenusWilliams" .
Title: Three columns mapping, concatenation of columns, by using a rr:sqlQuery to produce literal
Description: Tests: (1) three column mapping; and (2) concatenation of columns to produce literal, by using a rr:sqlQuery (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query "SELECT ID, LastName, concat_ws(FirstName, '', LastName) as Name FROM student"; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{LastName}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name"; rr:termType rr:Literal; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10/Williams> <http://xmlns.com/foaf/0.1/name> "VenusWilliams" .
Title: Three columns mapping, by using a rr:template to produce literal
Description: Tests: (1) three column mapping; and (2) the use of rr:template to produce literal
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student{ID}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{FirstName} {LastName}"; rr:termType rr:Literal; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" .
Title: Three columns mapping, by using a rr:template to produce literal
Description: Tests: (1) three column mapping; and (2) the use of rr:template to produce literal
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student{ID}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{FirstName} {LastName}"; rr:termType rr:Literal; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" .
Title: Three columns mapping, by using a rr:template to produce literal
Description: Tests: (1) three column mapping; and (2) the use of rr:template to produce literal (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student{ID}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{FirstName} {LastName}"; rr:termType rr:Literal; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" .
Title: Three columns mapping, by using a rr:template to produce literal
Description: Tests: (1) three column mapping; and (2) the use of rr:template to produce literal (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student{ID}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{FirstName} {LastName}"; rr:termType rr:Literal; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" .
Title: Three columns mapping, by using a rr:template to produce literal
Description: Tests: (1) three column mapping; and (2) the use of rr:template to produce literal (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student{ID}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{FirstName} {LastName}"; rr:termType rr:Literal; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" .
Title: Three columns mapping, by using a rr:template to produce literal
Description: Tests: (1) three column mapping; and (2) the use of rr:template to produce literal
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student{ID}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rr:template "{FirstName} {LastName}"; rr:termType rr:Literal; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" .
Title: Two column mapping, from one row table to two different triples
Description: Tests: (1) two column mapping, (2) subject URI generated by a column value; (3) from one row table to two different triples (4) typing by using rr:class
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Student}"; rr:class ex:Student ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Student" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Sport}"; rr:class ex:Sport ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Sport" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> . <http://example.com/Tennis> <http://xmlns.com/foaf/0.1/name> "Tennis" . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Sport> .
Title: Two column mapping, from one row table to two different triples
Description: Tests: (1) two column mapping, (2) subject URI generated by a column value; (3) from one row table to two different triples (4) typing by using rr:class
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Student}"; rr:class ex:Student ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Student" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Sport}"; rr:class ex:Sport ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Sport" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> . <http://example.com/Tennis> <http://xmlns.com/foaf/0.1/name> "Tennis" . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Sport> .
Title: Two column mapping, from one row table to two different triples
Description: Tests: (1) two column mapping, (2) subject URI generated by a column value; (3) from one row table to two different triples (4) typing by using rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/{Student}"; rr:class ex:Student ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Student" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/{Sport}"; rr:class ex:Sport ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Sport" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> . <http://example.com/Tennis> <http://xmlns.com/foaf/0.1/name> "Tennis" . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Sport> .
Title: Two column mapping, from one row table to two different triples
Description: Tests: (1) two column mapping, (2) subject URI generated by a column value; (3) from one row table to two different triples (4) typing by using rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/{Student}"; rr:class ex:Student ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Student" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/{Sport}"; rr:class ex:Sport ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Sport" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> . <http://example.com/Tennis> <http://xmlns.com/foaf/0.1/name> "Tennis" . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Sport> .
Title: Two column mapping, from one row table to two different triples
Description: Tests: (1) two column mapping, (2) subject URI generated by a column value; (3) from one row table to two different triples (4) typing by using rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/{Student}"; rr:class ex:Student ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Student" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/{Sport}"; rr:class ex:Sport ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Sport" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> . <http://example.com/Tennis> <http://xmlns.com/foaf/0.1/name> "Tennis" . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Sport> .
Title: Two column mapping, from one row table to two different triples
Description: Tests: (1) two column mapping, (2) subject URI generated by a column value; (3) from one row table to two different triples (4) typing by using rr:class
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{Student}"; rr:class ex:Student ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Student" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{Sport}"; rr:class ex:Sport ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Sport" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> . <http://example.com/Tennis> <http://xmlns.com/foaf/0.1/name> "Tennis" . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Sport> .
Title: One column mapping, presence of rr:termType rr:Literal on rr:subjectMap
Description: Tests: (1) one column mapping (2) the presence of rr:termType rr:Literal on rr:subjectMap, which is invalid
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Name}"; rr:termType rr:Literal ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: One column mapping, presence of rr:termType rr:Literal on rr:subjectMap
Description: Tests: (1) one column mapping (2) the presence of rr:termType rr:Literal on rr:subjectMap, which is invalid
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Name}"; rr:termType rr:Literal ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: One column mapping, presence of rr:termType rr:Literal on rr:subjectMap
Description: Tests: (1) one column mapping (2) the presence of rr:termType rr:Literal on rr:subjectMap, which is invalid (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}"; rr:termType rr:Literal ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: One column mapping, presence of rr:termType rr:Literal on rr:subjectMap
Description: Tests: (1) one column mapping (2) the presence of rr:termType rr:Literal on rr:subjectMap, which is invalid (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}"; rr:termType rr:Literal ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: One column mapping, presence of rr:termType rr:Literal on rr:subjectMap
Description: Tests: (1) one column mapping (2) the presence of rr:termType rr:Literal on rr:subjectMap, which is invalid (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Name}"; rr:termType rr:Literal ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: One column mapping, presence of rr:termType rr:Literal on rr:subjectMap
Description: Tests: (1) one column mapping (2) the presence of rr:termType rr:Literal on rr:subjectMap, which is invalid
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{Name}"; rr:termType rr:Literal ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Typing of resources
Description: Tests the typing of resources
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "ious.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{fname};{lname}"; rr:class foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:owes; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Bob;Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Bob;Smith> <http://example.com/owes> "30.0E0" . <http://example.com/Sue;Jones> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Sue;Jones> <http://example.com/owes> "20.0E0" .
Title: Typing of resources
Description: Tests the typing of resources
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "ious.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:subjectMap [ rr:template "http://example.com/{fname};{lname}"; rr:class foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:owes; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Bob;Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Bob;Smith> <http://example.com/owes> "30.0E0" . <http://example.com/Sue;Jones> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Sue;Jones> <http://example.com/owes> "20.0E0" .
Title: Typing of resources
Description: Tests the typing of resources (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "http://example.com/{fname};{lname}"; rr:class foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:owes; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Bob;Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Bob;Smith> <http://example.com/owes> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Sue;Jones> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Sue;Jones> <http://example.com/owes> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Typing of resources
Description: Tests the typing of resources (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "http://example.com/{fname};{lname}"; rr:class foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:owes; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Bob;Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Bob;Smith> <http://example.com/owes> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Sue;Jones> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Sue;Jones> <http://example.com/owes> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Typing of resources
Description: Tests the typing of resources (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "http://example.com/{fname};{lname}"; rr:class foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:owes; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Bob;Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Bob;Smith> <http://example.com/owes> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Sue;Jones> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Sue;Jones> <http://example.com/owes> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Typing of resources
Description: Tests the typing of resources
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "ious.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/persons/person" ]; rr:subjectMap [ rr:template "http://example.com/{fname};{lname}"; rr:class foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:owes; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Bob;Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Bob;Smith> <http://example.com/owes> "30.0E0" . <http://example.com/Sue;Jones> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Sue;Jones> <http://example.com/owes> "20.0E0" .
Title: Default mapping
Description: Tests the generation of a default mapping for tables without a primary key (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}"; rr:class <IOUs>; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname>; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname>; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#amount>; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Bob_Smith <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith <http://example.com/base/IOUs#amount> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Sue_Jones <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Sue_Jones <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones <http://example.com/base/IOUs#amount> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Default mapping
Description: Tests the generation of a default mapping for tables without a primary key (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}"; rr:class <IOUs>; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname>; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname>; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#amount>; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Bob_Smith <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith <http://example.com/base/IOUs#amount> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Sue_Jones <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Sue_Jones <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones <http://example.com/base/IOUs#amount> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Default mapping
Description: Tests the generation of a default mapping for tables without a primary key (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}"; rr:class <IOUs>; rr:termType rr:BlankNode ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname>; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname>; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#amount>; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Bob_Smith <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith <http://example.com/base/IOUs#amount> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Sue_Jones <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Sue_Jones <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones <http://example.com/base/IOUs#amount> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Long form of R2RML by using rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap
Description: Tests the use of rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:constant ex:BadStudent; rr:graphMap [ rr:constant <http://example.com/graph/student> ]; ]; rr:predicateObjectMap [ rr:predicateMap [ rr:constant ex:description ]; rr:objectMap [ rr:constant "Bad Student"; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BadStudent> <http://example.com/description> "Bad Student" <http://example.com/graph/student> .
Title: Long form of R2RML by using rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap
Description: Tests the use of rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:constant ex:BadStudent; rr:graphMap [ rr:constant <http://example.com/graph/student> ]; ]; rr:predicateObjectMap [ rr:predicateMap [ rr:constant ex:description ]; rr:objectMap [ rr:constant "Bad Student"; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BadStudent> <http://example.com/description> "Bad Student" <http://example.com/graph/student> .
Title: Long form of R2RML by using rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap
Description: Tests the use of rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:constant ex:BadStudent; rr:graphMap [ rr:constant <http://example.com/graph/student> ]; ]; rr:predicateObjectMap [ rr:predicateMap [ rr:constant ex:description ]; rr:objectMap [ rr:constant "Bad Student"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BadStudent> <http://example.com/description> "Bad Student" <http://example.com/graph/student> .
Title: Long form of R2RML by using rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap
Description: Tests the use of rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:constant ex:BadStudent; rr:graphMap [ rr:constant <http://example.com/graph/student> ]; ]; rr:predicateObjectMap [ rr:predicateMap [ rr:constant ex:description ]; rr:objectMap [ rr:constant "Bad Student"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BadStudent> <http://example.com/description> "Bad Student" <http://example.com/graph/student> .
Title: Long form of R2RML by using rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap
Description: Tests the use of rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:constant ex:BadStudent; rr:graphMap [ rr:constant <http://example.com/graph/student> ]; ]; rr:predicateObjectMap [ rr:predicateMap [ rr:constant ex:description ]; rr:objectMap [ rr:constant "Bad Student"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BadStudent> <http://example.com/description> "Bad Student" <http://example.com/graph/student> .
Title: Long form of R2RML by using rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap
Description: Tests the use of rr:constant in rr:subjectMap, rr:predicateMap, rr:objectMap and rr:graphMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:constant ex:BadStudent; rr:graphMap [ rr:constant <http://example.com/graph/student> ]; ]; rr:predicateObjectMap [ rr:predicateMap [ rr:constant ex:description ]; rr:objectMap [ rr:constant "Bad Student"; ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BadStudent> <http://example.com/description> "Bad Student" <http://example.com/graph/student> .
Title: Typing resources by relying on rdf:type predicate
Description: Tests the typing resources by relying on rdf:type predicate (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Typing resources by relying on rdf:type predicate
Description: Tests the typing resources by relying on rdf:type predicate (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Typing resources by relying on rdf:type predicate
Description: Tests the typing resources by relying on rdf:type predicate (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Typing resources by relying on rdf:type predicate
Description: Tests the typing resources by relying on rdf:type predicate (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Typing resources by relying on rdf:type predicate
Description: Tests the typing resources by relying on rdf:type predicate (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Typing resources by relying on rdf:type predicate
Description: Tests the typing resources by relying on rdf:type predicate (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Assigning triples to Named Graphs
Description: Tests the generation of triples to a named graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: Assigning triples to Named Graphs
Description: Tests the generation of triples to a named graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: Assigning triples to Named Graphs
Description: Tests the generation of triples to a named graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: Assigning triples to Named Graphs
Description: Tests the generation of triples to a named graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: Assigning triples to Named Graphs
Description: Tests the generation of triples to a named graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: Assigning triples to Named Graphs
Description: Tests the generation of triples to a named graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: One row mapping, using rr:class
Description: Tests subjectmap with more than one class IRIs, rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:class foaf:Person, ex:Student ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10" . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One row mapping, using rr:class
Description: Tests subjectmap with more than one class IRIs, rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:class foaf:Person, ex:Student ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10" . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One row mapping, using rr:class
Description: Tests subjectmap with more than one class IRIs, rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:class foaf:Person, ex:Student ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One row mapping, using rr:class
Description: Tests subjectmap with more than one class IRIs, rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:class foaf:Person, ex:Student ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One row mapping, using rr:class
Description: Tests subjectmap with more than one class IRIs, rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:class foaf:Person, ex:Student ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One row mapping, using rr:class
Description: Tests subjectmap with more than one class IRIs, rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:class foaf:Person, ex:Student ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10" . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One column mapping, specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with an alternative of having rr:class, i.e., by specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object ex:Student; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10" . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One column mapping, specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with an alternative of having rr:class, i.e., by specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object ex:Student; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [rml:reference "ID"] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10" . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One column mapping, specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with an alternative of having rr:class, i.e., by specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object ex:Student; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One column mapping, specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with an alternative of having rr:class, i.e., by specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object ex:Student; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One column mapping, specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with an alternative of having rr:class, i.e., by specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object ex:Student; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One column mapping, specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with an alternative of having rr:class, i.e., by specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}" ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object ex:Student; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [rml:reference "ID"] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" . <http://example.com/Student/10/Venus> <http://example.com/id> "10" . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/Student> .
Title: One column mapping, using rr:graphMap and rr:class
Description: Tests subjectmap with rr:graphMap and rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graph ex:PersonGraph ; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://example.com/id> "10" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and rr:class
Description: Tests subjectmap with rr:graphMap and rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graph ex:PersonGraph ; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://example.com/id> "10" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and rr:class
Description: Tests subjectmap with rr:graphMap and rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and rr:class
Description: Tests subjectmap with rr:graphMap and rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and rr:class
Description: Tests subjectmap with rr:graphMap and rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and rr:class
Description: Tests subjectmap with rr:graphMap and rr:class (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graph ex:PersonGraph ; rr:class foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://example.com/id> "10" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with rr:graphMap and specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://example.com/id> "10" <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with rr:graphMap and specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://example.com/id> "10" <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with rr:graphMap and specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with rr:graphMap and specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with rr:graphMap and specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/PersonGraph> .
Title: One column mapping, using rr:graphMap and specifying an rr:predicateObjectMap with rdf:type
Description: Tests subjectmap with rr:graphMap and specifying an rr:predicateObjectMap with predicate rdf:type (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph ex:PersonGraph ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" <http://example.com/PersonGraph> . <http://example.com/Student/10/Venus> <http://example.com/id> "10" <http://example.com/PersonGraph> .
Title: Assigning triples to the default graph
Description: Tests the generation of triples to the default graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph rr:defaultGraph ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Assigning triples to the default graph
Description: Tests the generation of triples to the default graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph rr:defaultGraph ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Assigning triples to the default graph
Description: Tests the generation of triples to the default graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph rr:defaultGraph ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Assigning triples to the default graph
Description: Tests the generation of triples to the default graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph rr:defaultGraph ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Assigning triples to the default graph
Description: Tests the generation of triples to the default graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph rr:defaultGraph ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Assigning triples to the default graph
Description: Tests the generation of triples to the default graph (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph rr:defaultGraph ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus> <http://xmlns.com/foaf/0.1/name> "Venus" .
Title: Assigning triples to a non-IRI named graph
Description: Tests the generation of triples to a non-IRI named graph, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph [ rml:reference "Name"; rr:termType rr:Literal; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
Title: Assigning triples to a non-IRI named graph
Description: Tests the generation of triples to a non-IRI named graph, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph [ rml:reference "Name"; rr:termType rr:Literal; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
Title: Assigning triples to a non-IRI named graph
Description: Tests the generation of triples to a non-IRI named graph, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph [ rml:reference "Name"; rr:termType rr:Literal; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
Title: Assigning triples to a non-IRI named graph
Description: Tests the generation of triples to a non-IRI named graph, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph [ rml:reference "Name"; rr:termType rr:Literal; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
Title: Assigning triples to a non-IRI named graph
Description: Tests the generation of triples to a non-IRI named graph, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph [ rml:reference "Name"; rr:termType rr:Literal; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
Title: Assigning triples to a non-IRI named graph
Description: Tests the generation of triples to a non-IRI named graph, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{FirstName}"; rr:graph [ rml:reference "Name"; rr:termType rr:Literal; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "Name" ] ].
Error expected: No
Expected knowledge graph: (download)
Title: Generation of triples to a target graph by using rr:graphMap and rr:template
Description: Test that results of the mapping can be directed to a target graph by using rr:graphMap and rr:template (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graphMap [ rr:template "http://example.com/graph/Student/{ID}/{Name}" ] ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap [ rml:reference "Sport" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> "Tennis" <http://example.com/graph/Student/10/Venus%20Williams> .
Title: Generation of triples to a target graph by using rr:graphMap and rr:template
Description: Test that results of the mapping can be directed to a target graph by using rr:graphMap and rr:template (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graphMap [ rr:template "http://example.com/graph/Student/{ID}/{Name}" ] ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap [ rml:reference "Sport" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> "Tennis" <http://example.com/graph/Student/10/Venus%20Williams> .
Title: Generation of triples to a target graph by using rr:graphMap and rr:template
Description: Test that results of the mapping can be directed to a target graph by using rr:graphMap and rr:template (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graphMap [ rr:template "http://example.com/graph/Student/{ID}/{Name}" ] ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap [ rml:reference "Sport" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> "Tennis" <http://example.com/graph/Student/10/Venus%20Williams> .
Title: Generation of triples to a target graph by using rr:graphMap and rr:template
Description: Test that results of the mapping can be directed to a target graph by using rr:graphMap and rr:template (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graphMap [ rr:template "http://example.com/graph/Student/{ID}/{Name}" ] ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap [ rml:reference "Sport" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> "Tennis" <http://example.com/graph/Student/10/Venus%20Williams> .
Title: Generation of triples to a target graph by using rr:graphMap and rr:template
Description: Test that results of the mapping can be directed to a target graph by using rr:graphMap and rr:template (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graphMap [ rr:template "http://example.com/graph/Student/{ID}/{Name}" ] ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap [ rml:reference "Sport" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> "Tennis" <http://example.com/graph/Student/10/Venus%20Williams> .
Title: Generation of triples to a target graph by using rr:graphMap and rr:template
Description: Test that results of the mapping can be directed to a target graph by using rr:graphMap and rr:template (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}"; rr:graphMap [ rr:template "http://example.com/graph/Student/{ID}/{Name}" ] ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap [ rml:reference "Sport" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10" <http://example.com/graph/Student/10/Venus%20Williams> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> "Tennis" <http://example.com/graph/Student/10/Venus%20Williams> .
Title: Generation of triples referencing object map
Description: Tests the mapping specification referencing object map without join (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Sport}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object activity:Sport ; ] . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person ; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap <RefObjectMap1> ] . <RefObjectMap1> a rr:RefObjectMap; rr:parentTriplesMap <TriplesMap2> .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> <http://example.com/Tennis> . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/activity/Sport> .
Title: Generation of triples referencing object map
Description: Tests the mapping specification referencing object map without join (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Sport}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object activity:Sport ; ] . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person ; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap <RefObjectMap1> ] . <RefObjectMap1> a rr:RefObjectMap; rr:parentTriplesMap <TriplesMap2> .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> <http://example.com/Tennis> . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/activity/Sport> .
Title: Generation of triples referencing object map
Description: Tests the mapping specification referencing object map without join (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Sport}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object activity:Sport ; ] . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person ; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap <RefObjectMap1> ] . <RefObjectMap1> a rr:RefObjectMap; rr:parentTriplesMap <TriplesMap2> . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> <http://example.com/Tennis> . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/activity/Sport> .
Title: Generation of triples referencing object map
Description: Tests the mapping specification referencing object map without join (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Sport}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object activity:Sport ; ] . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person ; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap <RefObjectMap1> ] . <RefObjectMap1> a rr:RefObjectMap; rr:parentTriplesMap <TriplesMap2> . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> <http://example.com/Tennis> . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/activity/Sport> .
Title: Generation of triples referencing object map
Description: Tests the mapping specification referencing object map without join (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/{Sport}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object activity:Sport ; ] . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person ; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap <RefObjectMap1> ] . <RefObjectMap1> a rr:RefObjectMap; rr:parentTriplesMap <TriplesMap2> . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> <http://example.com/Tennis> . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/activity/Sport> .
Title: Generation of triples referencing object map
Description: Tests the mapping specification referencing object map without join (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/{Sport}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object activity:Sport ; ] . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate rdf:type ; rr:object foaf:Person ; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ]; rr:predicateObjectMap [ rr:predicate ex:Sport ; rr:objectMap <RefObjectMap1> ] . <RefObjectMap1> a rr:RefObjectMap; rr:parentTriplesMap <TriplesMap2> .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/id> "10" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/Sport> <http://example.com/Tennis> . <http://example.com/Tennis> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/activity/Sport> .
Title: Generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
Description: Tests the generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/name> "Venus Williams" .
Title: Generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
Description: Tests the generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/name> "Venus Williams" .
Title: Generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
Description: Tests the generation of triples by using multiple predicateMaps within a rr:predicateObjectMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/name> "Venus Williams" .
Title: Generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
Description: Tests the generation of triples by using multiple predicateMaps within a rr:predicateObjectMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/name> "Venus Williams" .
Title: Generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
Description: Tests the generation of triples by using multiple predicateMaps within a rr:predicateObjectMap (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/name> "Venus Williams" .
Title: Generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
Description: Tests the generation of triples by using multiple predicateMaps within a rr:predicateObjectMap
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/Student/{ID}/{Name}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Student/10/Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/Student/10/Venus%20Williams> <http://example.com/name> "Venus Williams" .
Title: Generation of triples from foreign key relations
Description: Test foreign key relationships among logical tables (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> .
Title: Generation of triples from foreign key relations
Description: Test foreign key relationships among logical tables (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.sports[*]" ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> .
Title: Generation of triples from foreign key relations
Description: Test foreign key relationships among logical tables (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> .
Title: Generation of triples from foreign key relations
Description: Test foreign key relationships among logical tables (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> .
Title: Generation of triples from foreign key relations
Description: Test foreign key relationships among logical tables (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> .
Title: Generation of triples from foreign key relations
Description: Test foreign key relationships among logical tables (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/sports/sport" ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> .
Title: Generation of triples to multiple graphs
Description: Test that results from distinct parts of the mapping can be directed to different target graphs. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ; rr:class <http://example.com/ontology/Student>; rr:graph <http://example.com/graph/students> ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ]; rr:graph <http://example.com/graph/students> ; ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ]; rr:graph <http://example.com/graph/practise> ; ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}"; rr:class <http://example.com/ontology/Sport>; rr:graph <http://example.com/graph/sports> ; ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" <http://example.com/graph/students> . <http://example.com/resource/sport_100> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Sport> <http://example.com/graph/sports> . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" <http://example.com/graph/sports> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/practise> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/students> .
Title: Generation of triples to multiple graphs
Description: Test that results from distinct parts of the mapping can be directed to different target graphs. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}"; rr:class <http://example.com/ontology/Student>; rr:graph <http://example.com/graph/students> ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ]; rr:graph <http://example.com/graph/students> ; ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ]; rr:graph <http://example.com/graph/practise> ; ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.sports[*]" ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}"; rr:class <http://example.com/ontology/Sport>; rr:graph <http://example.com/graph/sports> ; ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" <http://example.com/graph/students> . <http://example.com/resource/sport_100> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Sport> <http://example.com/graph/sports> . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" <http://example.com/graph/sports> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/practise> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/students> .
Title: Generation of triples to multiple graphs
Description: Test that results from distinct parts of the mapping can be directed to different target graphs. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ; rr:class <http://example.com/ontology/Student>; rr:graph <http://example.com/graph/students> ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ]; rr:graph <http://example.com/graph/students> ; ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ]; rr:graph <http://example.com/graph/practise> ; ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}"; rr:class <http://example.com/ontology/Sport>; rr:graph <http://example.com/graph/sports> ; ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" <http://example.com/graph/students> . <http://example.com/resource/sport_100> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Sport> <http://example.com/graph/sports> . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" <http://example.com/graph/sports> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/practise> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/students> .
Title: Generation of triples to multiple graphs
Description: Test that results from distinct parts of the mapping can be directed to different target graphs. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ; rr:class <http://example.com/ontology/Student>; rr:graph <http://example.com/graph/students> ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ]; rr:graph <http://example.com/graph/students> ; ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ]; rr:graph <http://example.com/graph/practise> ; ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}"; rr:class <http://example.com/ontology/Sport>; rr:graph <http://example.com/graph/sports> ; ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" <http://example.com/graph/students> . <http://example.com/resource/sport_100> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Sport> <http://example.com/graph/sports> . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" <http://example.com/graph/sports> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/practise> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/students> .
Title: Generation of triples to multiple graphs
Description: Test that results from distinct parts of the mapping can be directed to different target graphs. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}" ; rr:class <http://example.com/ontology/Student>; rr:graph <http://example.com/graph/students> ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ]; rr:graph <http://example.com/graph/students> ; ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ]; rr:graph <http://example.com/graph/practise> ; ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}"; rr:class <http://example.com/ontology/Sport>; rr:graph <http://example.com/graph/sports> ; ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" <http://example.com/graph/students> . <http://example.com/resource/sport_100> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Sport> <http://example.com/graph/sports> . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" <http://example.com/graph/sports> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/practise> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/students> .
Title: Generation of triples to multiple graphs
Description: Test that results from distinct parts of the mapping can be directed to different target graphs. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{ID}"; rr:class <http://example.com/ontology/Student>; rr:graph <http://example.com/graph/students> ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ]; rr:graph <http://example.com/graph/students> ; ] ; rr:predicateObjectMap [ rr:predicate <http://example.com/ontology/practises> ; rr:objectMap [ a rr:RefObjectMap ; rr:parentTriplesMap <TriplesMap2>; rr:joinCondition [ rr:child "Sport" ; rr:parent "ID" ; ] ]; rr:graph <http://example.com/graph/practise> ; ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/sports/sport" ]; rr:subjectMap [ rr:template "http://example.com/resource/sport_{ID}"; rr:class <http://example.com/ontology/Sport>; rr:graph <http://example.com/graph/sports> ; ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name" ]; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_10> <http://xmlns.com/foaf/0.1/name> "Venus Williams" <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Student> <http://example.com/graph/students> . <http://example.com/resource/student_20> <http://xmlns.com/foaf/0.1/name> "Demi Moore" <http://example.com/graph/students> . <http://example.com/resource/sport_100> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/ontology/Sport> <http://example.com/graph/sports> . <http://example.com/resource/sport_100> <http://www.w3.org/2000/01/rdf-schema#label> "Tennis" <http://example.com/graph/sports> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/practise> . <http://example.com/resource/student_10> <http://example.com/ontology/practises> <http://example.com/resource/sport_100> <http://example.com/graph/students> .
Title: Unnamed column in a logical table
Description: Test a logical table with unnamed column. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Name, COUNT(Sport) FROM Student GROUP BY Name """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{Name}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name"; ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_Demi%20Moore> <http://xmlns.com/foaf/0.1/name> "Demi Moore" .
Title: Unnamed column in a logical table
Description: Test a logical table with unnamed column. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Name, COUNT(Sport) FROM Student GROUP BY Name """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{name}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "name"; ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_Demi%20Moore> <http://xmlns.com/foaf/0.1/name> "Demi Moore" .
Title: Unnamed column in a logical table
Description: Test a logical table with unnamed column. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Name, COUNT(Sport) FROM Student GROUP BY Name """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{Name}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name"; ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_Demi%20Moore> <http://xmlns.com/foaf/0.1/name> "Demi Moore" .
Title: Named column in logical table
Description: Test a logical table named column. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Name, COUNT(Sport) as SPORTCOUNT FROM Student GROUP BY Name """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{Name}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name"; ]; ]; rr:predicateObjectMap [ rr:predicate ex:numSport ; rr:objectMap [ rml:reference "SPORTCOUNT"; ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_Venus%20Williams> <http://example.com/numSport> "1"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/resource/student_Demi%20Moore> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/student_Demi%20Moore> <http://example.com/numSport> "0"^^<http://www.w3.org/2001/XMLSchema#integer> .
Title: Named column in logical table
Description: Test a logical table named column. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Name, COUNT(Sport) as SPORTCOUNT FROM Student GROUP BY Name """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{name}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "name"; ]; ]; rr:predicateObjectMap [ rr:predicate ex:numSport ; rr:objectMap [ rml:reference "sportcount"; ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_Venus%20Williams> <http://example.com/numSport> "1"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/resource/student_Demi%20Moore> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/student_Demi%20Moore> <http://example.com/numSport> "0"^^<http://www.w3.org/2001/XMLSchema#integer> .
Title: Named column in logical table
Description: Test a logical table named column. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Name, COUNT(Sport) as SPORTCOUNT FROM Student GROUP BY Name """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/resource/student_{Name}"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name"; ]; ]; rr:predicateObjectMap [ rr:predicate ex:numSport ; rr:objectMap [ rml:reference "SPORTCOUNT"; ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/resource/student_Venus%20Williams> <http://xmlns.com/foaf/0.1/name> "Venus Williams" . <http://example.com/resource/student_Venus%20Williams> <http://example.com/numSport> "1"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/resource/student_Demi%20Moore> <http://xmlns.com/foaf/0.1/name> "Demi Moore" . <http://example.com/resource/student_Demi%20Moore> <http://example.com/numSport> "0"^^<http://www.w3.org/2001/XMLSchema#integer> .
Title: Template with table column with special chars
Description: Tests a template with blank space in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2> <http://example.com/name> "Ireland" . <http://example.com/3> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table column with special chars
Description: Tests a template with blank space in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.countries[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2> <http://example.com/name> "Ireland" . <http://example.com/3> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table column with special chars
Description: Tests a template with blank space in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2> <http://example.com/name> "Ireland" . <http://example.com/3> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table column with special chars
Description: Tests a template with blank space in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2> <http://example.com/name> "Ireland" . <http://example.com/3> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table column with special chars
Description: Tests a template with blank space in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2> <http://example.com/name> "Ireland" . <http://example.com/3> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table columns with special chars
Description: Tests a template with special chars in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2/Ireland> <http://example.com/name> "Ireland" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table columns with special chars
Description: Tests a template with special chars in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.countries[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2/Ireland> <http://example.com/name> "Ireland" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table columns with special chars
Description: Tests a template with special chars in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2/Ireland> <http://example.com/name> "Ireland" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table columns with special chars
Description: Tests a template with special chars in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2/Ireland> <http://example.com/name> "Ireland" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table columns with special chars
Description: Tests a template with special chars in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2/Ireland> <http://example.com/name> "Ireland" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table columns with special chars
Description: Tests a template with special chars in column value (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/countries/country" ]; rr:subjectMap [ rr:template "http://example.com/{CountryCode}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:name ; rr:objectMap [ rml:reference "Name" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/name> "Bolivia, Plurinational State of" . <http://example.com/2/Ireland> <http://example.com/name> "Ireland" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/name> "Saint Martin (French part)" .
Title: Template with table columns with special chars and backslashes
Description: Tests a template with special chars in reference value and backslash escapes in string templates (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:code ; rr:objectMap [ rr:template "\{\{\{ {ISO 3166} \}\}\}"; rr:termType rr:Literal] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/code> "{{{ BO }}}" . <http://example.com/2/Ireland> <http://example.com/code> "{{{ IE }}}" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/code> "{{{ MF }}}" .
Title: Template with table columns with special chars and backslashes
Description: Tests a template with special chars in reference value and backslash escapes in string templates (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.countries[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:code ; rr:objectMap [ rr:template "\{\{\{ {ISO 3166} \}\}\}"; rr:termType rr:Literal] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/code> "{{{ BO }}}" . <http://example.com/2/Ireland> <http://example.com/code> "{{{ IE }}}" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/code> "{{{ MF }}}" .
Title: Template with table columns with special chars and backslashes
Description: Tests a template with special chars in column value and backslash escapes in string templates (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:code ; rr:objectMap [ rr:template "\{\{\{ {ISO 3166} \}\}\}"; rr:termType rr:Literal] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/code> "{{{ BO }}}" . <http://example.com/2/Ireland> <http://example.com/code> "{{{ IE }}}" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/code> "{{{ MF }}}" .
Title: Template with table columns with special chars and backslashes
Description: Tests a template with special chars in column value and backslash escapes in string templates (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:code ; rr:objectMap [ rr:template "\{\{\{ {ISO 3166} \}\}\}"; rr:termType rr:Literal] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/code> "{{{ BO }}}" . <http://example.com/2/Ireland> <http://example.com/code> "{{{ IE }}}" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/code> "{{{ MF }}}" .
Title: Template with table columns with special chars and backslashes
Description: Tests a template with special chars in column value and backslash escapes in string templates (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "country_info"; ]; rr:subjectMap [ rr:template "http://example.com/{Country Code}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:code ; rr:objectMap [ rr:template "\{\{\{ {ISO 3166} \}\}\}"; rr:termType rr:Literal] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/code> "{{{ BO }}}" . <http://example.com/2/Ireland> <http://example.com/code> "{{{ IE }}}" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/code> "{{{ MF }}}" .
Title: Template with table columns with special chars and backslashes
Description: Tests a template with special chars in reference value and backslash escapes in string templates (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix activity: <http://example.com/activity/> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_info.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/countries/country" ]; rr:subjectMap [ rr:template "http://example.com/{CountryCode}/{Name}" ]; rr:predicateObjectMap [ rr:predicate ex:code ; rr:objectMap [ rr:template "\{\{\{ {ISO3166} \}\}\}"; rr:termType rr:Literal] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/1/Bolivia%2C%20Plurinational%20State%20of> <http://example.com/code> "{{{ BO }}}" . <http://example.com/2/Ireland> <http://example.com/code> "{{{ IE }}}" . <http://example.com/3/Saint%20Martin%20%28French%20part%29> <http://example.com/code> "{{{ MF }}}" .
Title: M to M relation, by using a SQL query
Description: Tests, M to M relations, by using a SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Student.ID as ID, Student.FirstName as FirstName, Student.LastName as LastName, Sport.Description as Description, Sport.ID as Sport_ID FROM Student,Sport,Student_Sport WHERE Student.ID = Student_Sport.ID_Student AND Sport.ID = Student_Sport.ID_Sport; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{FirstName};{LastName}" ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate ex:firstName ; rr:objectMap [ rml:reference "FirstName" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName ; rr:objectMap [ rml:reference "LastName" ] ]; rr:predicateObjectMap [ rr:predicate ex:plays ; rr:objectMap [ rr:template "http://example.com/{Sport_ID}/{Description}" ] ] . <TriplesMap2> a rr:TriplesMap; rr:logicalTable [ rr:tableName "Sport" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Description}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate ex:description ; rr:objectMap [ rml:reference "Description" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/110/Tennis> <http://example.com/description> "Tennis" . <http://example.com/110/Tennis> <http://example.com/id> "110"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10/Venus;Williams> <http://example.com/plays> <http://example.com/110/Tennis> . <http://example.com/10/Venus;Williams> <http://example.com/lastName> "Williams" . <http://example.com/10/Venus;Williams> <http://example.com/firstName> "Venus" . <http://example.com/10/Venus;Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/111/Football> <http://example.com/description> "Football" . <http://example.com/111/Football> <http://example.com/id> "111"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/12/David;Villa> <http://example.com/plays> <http://example.com/111/Football> . <http://example.com/12/David;Villa> <http://example.com/lastName> "Villa" . <http://example.com/12/David;Villa> <http://example.com/firstName> "David" . <http://example.com/12/David;Villa> <http://example.com/id> "12"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/112/Formula1> <http://example.com/description> "Formula1" . <http://example.com/112/Formula1> <http://example.com/id> "112"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/11/Fernando;Alonso> <http://example.com/lastName> "Alonso" . <http://example.com/11/Fernando;Alonso> <http://example.com/firstName> "Fernando" . <http://example.com/11/Fernando;Alonso> <http://example.com/id> "11"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/11/Fernando;Alonso> <http://example.com/plays> <http://example.com/111/Football> . <http://example.com/11/Fernando;Alonso> <http://example.com/plays> <http://example.com/112/Formula1> .
Title: M to M relation, by using a SQL query
Description: Tests, M to M relations, by using a SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Student.ID as ID, Student.FirstName as FirstName, Student.LastName as LastName, Sport.Description as Description, Sport.ID as Sport_ID FROM Student,Sport,Student_Sport WHERE Student.ID = Student_Sport.ID_Student AND Sport.ID = Student_Sport.ID_Sport; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{id}/{firstname};{lastname}" ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "id"; ] ]; rr:predicateObjectMap [ rr:predicate ex:firstName ; rr:objectMap [ rml:reference "firstname" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName ; rr:objectMap [ rml:reference "lastname" ] ]; rr:predicateObjectMap [ rr:predicate ex:plays ; rr:objectMap [ rr:template "http://example.com/{sport_id}/{description}" ] ] . <TriplesMap2> a rr:TriplesMap; rr:logicalTable [ rr:tableName "Sport" ]; rr:subjectMap [ rr:template "http://example.com/{id}/{description}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "id"; ] ]; rr:predicateObjectMap [ rr:predicate ex:description ; rr:objectMap [ rml:reference "description" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/110/Tennis> <http://example.com/description> "Tennis" . <http://example.com/110/Tennis> <http://example.com/id> "110"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10/Venus;Williams> <http://example.com/plays> <http://example.com/110/Tennis> . <http://example.com/10/Venus;Williams> <http://example.com/lastName> "Williams" . <http://example.com/10/Venus;Williams> <http://example.com/firstName> "Venus" . <http://example.com/10/Venus;Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/111/Football> <http://example.com/description> "Football" . <http://example.com/111/Football> <http://example.com/id> "111"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/12/David;Villa> <http://example.com/plays> <http://example.com/111/Football> . <http://example.com/12/David;Villa> <http://example.com/lastName> "Villa" . <http://example.com/12/David;Villa> <http://example.com/firstName> "David" . <http://example.com/12/David;Villa> <http://example.com/id> "12"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/112/Formula1> <http://example.com/description> "Formula1" . <http://example.com/112/Formula1> <http://example.com/id> "112"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/11/Fernando;Alonso> <http://example.com/lastName> "Alonso" . <http://example.com/11/Fernando;Alonso> <http://example.com/firstName> "Fernando" . <http://example.com/11/Fernando;Alonso> <http://example.com/id> "11"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/11/Fernando;Alonso> <http://example.com/plays> <http://example.com/111/Football> . <http://example.com/11/Fernando;Alonso> <http://example.com/plays> <http://example.com/112/Formula1> .
Title: M to M relation, by using a SQL query
Description: Tests, M to M relations, by using a SQL query (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Student.ID as ID, Student.FirstName as FirstName, Student.LastName as LastName, Sport.Description as Description, Sport.ID as Sport_ID FROM Student,Sport,Student_Sport WHERE Student.ID = Student_Sport.ID_Student AND Sport.ID = Student_Sport.ID_Sport; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{FirstName};{LastName}" ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate ex:firstName ; rr:objectMap [ rml:reference "FirstName" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName ; rr:objectMap [ rml:reference "LastName" ] ]; rr:predicateObjectMap [ rr:predicate ex:plays ; rr:objectMap [ rr:template "http://example.com/{Sport_ID}/{Description}" ] ] . <TriplesMap2> a rr:TriplesMap; rr:logicalTable [ rr:tableName "Sport" ]; rr:subjectMap [ rr:template "http://example.com/{ID}/{Description}"; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate ex:description ; rr:objectMap [ rml:reference "Description" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/110/Tennis> <http://example.com/description> "Tennis" . <http://example.com/110/Tennis> <http://example.com/id> "110"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10/Venus;Williams> <http://example.com/plays> <http://example.com/110/Tennis> . <http://example.com/10/Venus;Williams> <http://example.com/lastName> "Williams" . <http://example.com/10/Venus;Williams> <http://example.com/firstName> "Venus" . <http://example.com/10/Venus;Williams> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/111/Football> <http://example.com/description> "Football" . <http://example.com/111/Football> <http://example.com/id> "111"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/12/David;Villa> <http://example.com/plays> <http://example.com/111/Football> . <http://example.com/12/David;Villa> <http://example.com/lastName> "Villa" . <http://example.com/12/David;Villa> <http://example.com/firstName> "David" . <http://example.com/12/David;Villa> <http://example.com/id> "12"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/112/Formula1> <http://example.com/description> "Formula1" . <http://example.com/112/Formula1> <http://example.com/id> "112"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/11/Fernando;Alonso> <http://example.com/lastName> "Alonso" . <http://example.com/11/Fernando;Alonso> <http://example.com/firstName> "Fernando" . <http://example.com/11/Fernando;Alonso> <http://example.com/id> "11"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/11/Fernando;Alonso> <http://example.com/plays> <http://example.com/111/Football> . <http://example.com/11/Fernando;Alonso> <http://example.com/plays> <http://example.com/112/Formula1> .
Title: M to M relation, by using an additional Triples Map
Description: Tests, M to M relations, by using an additional Triples Map
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/student/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "FirstName" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "LastName" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/sport/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate ex:description; rr:objectMap [ rml:reference "Description" ] ]. <LinkMap_1_2> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/student/{ID_Student}"; ]; rr:predicateObjectMap [ rr:predicate ex:plays; rr:objectMap [ rr:template "http://example.com/sport/{ID_Sport}" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/student/10> <http://example.com/lastName> "Williams" . <http://example.com/student/10> <http://example.com/firstName> "Venus" . <http://example.com/student/12> <http://example.com/lastName> "Villa" . <http://example.com/student/12> <http://example.com/firstName> "David" . <http://example.com/student/11> <http://example.com/lastName> "Alonso" . <http://example.com/student/11> <http://example.com/firstName> "Fernando" . <http://example.com/sport/110> <http://example.com/description> "Tennis" . <http://example.com/sport/110> <http://example.com/id> "110" . <http://example.com/sport/111> <http://example.com/description> "Football" . <http://example.com/sport/111> <http://example.com/id> "111" . <http://example.com/sport/112> <http://example.com/description> "Formula1" . <http://example.com/sport/112> <http://example.com/id> "112" . <http://example.com/student/10> <http://example.com/plays> <http://example.com/sport/110> . <http://example.com/student/12> <http://example.com/plays> <http://example.com/sport/111> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/112> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/111> .
Title: M to M relation, by using an additional Triples Map
Description: Tests, M to M relations, by using an additional Triples Map
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "http://example.com/student/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "FirstName" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "LastName" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.sports[*]" ]; rr:subjectMap [ rr:template "http://example.com/sport/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate ex:description; rr:objectMap [ rml:reference "Description" ] ]. <LinkMap_1_2> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.links[*]" ]; rr:subjectMap [ rr:template "http://example.com/student/{ID_Student}"; ]; rr:predicateObjectMap [ rr:predicate ex:plays; rr:objectMap [ rr:template "http://example.com/sport/{ID_Sport}" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/student/10> <http://example.com/lastName> "Williams" . <http://example.com/student/10> <http://example.com/firstName> "Venus" . <http://example.com/student/12> <http://example.com/lastName> "Villa" . <http://example.com/student/12> <http://example.com/firstName> "David" . <http://example.com/student/11> <http://example.com/lastName> "Alonso" . <http://example.com/student/11> <http://example.com/firstName> "Fernando" . <http://example.com/sport/110> <http://example.com/description> "Tennis" . <http://example.com/sport/110> <http://example.com/id> "110" . <http://example.com/sport/111> <http://example.com/description> "Football" . <http://example.com/sport/111> <http://example.com/id> "111" . <http://example.com/sport/112> <http://example.com/description> "Formula1" . <http://example.com/sport/112> <http://example.com/id> "112" . <http://example.com/student/10> <http://example.com/plays> <http://example.com/sport/110> . <http://example.com/student/12> <http://example.com/plays> <http://example.com/sport/111> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/112> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/111> .
Title: M to M relation, by using an additional Triples Map
Description: Tests, M to M relations, by using an additional Triples Map (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/student/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "FirstName" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "LastName" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/sport/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate ex:description; rr:objectMap [ rml:reference "Description" ] ]. <LinkMap_1_2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/student/{ID_Student}"; ]; rr:predicateObjectMap [ rr:predicate ex:plays; rr:objectMap [ rr:template "http://example.com/sport/{ID_Sport}" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/student/10> <http://example.com/lastName> "Williams" . <http://example.com/student/10> <http://example.com/firstName> "Venus" . <http://example.com/student/12> <http://example.com/lastName> "Villa" . <http://example.com/student/12> <http://example.com/firstName> "David" . <http://example.com/student/11> <http://example.com/lastName> "Alonso" . <http://example.com/student/11> <http://example.com/firstName> "Fernando" . <http://example.com/sport/110> <http://example.com/description> "Tennis" . <http://example.com/sport/110> <http://example.com/id> "110"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/sport/111> <http://example.com/description> "Football" . <http://example.com/sport/111> <http://example.com/id> "111"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/sport/112> <http://example.com/description> "Formula1" . <http://example.com/sport/112> <http://example.com/id> "112"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/student/10> <http://example.com/plays> <http://example.com/sport/110> . <http://example.com/student/12> <http://example.com/plays> <http://example.com/sport/111> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/112> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/111> .
Title: M to M relation, by using an additional Triples Map
Description: Tests, M to M relations, by using an additional Triples Map (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/student/{id}"; ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "firstname" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "lastname" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/sport/{id}"; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "id" ] ]; rr:predicateObjectMap [ rr:predicate ex:description; rr:objectMap [ rml:reference "description" ] ]. <LinkMap_1_2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/student/{id_student}"; ]; rr:predicateObjectMap [ rr:predicate ex:plays; rr:objectMap [ rr:template "http://example.com/sport/{id_sport}" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/student/10> <http://example.com/lastName> "Williams" . <http://example.com/student/10> <http://example.com/firstName> "Venus" . <http://example.com/student/12> <http://example.com/lastName> "Villa" . <http://example.com/student/12> <http://example.com/firstName> "David" . <http://example.com/student/11> <http://example.com/lastName> "Alonso" . <http://example.com/student/11> <http://example.com/firstName> "Fernando" . <http://example.com/sport/110> <http://example.com/description> "Tennis" . <http://example.com/sport/110> <http://example.com/id> "110"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/sport/111> <http://example.com/description> "Football" . <http://example.com/sport/111> <http://example.com/id> "111"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/sport/112> <http://example.com/description> "Formula1" . <http://example.com/sport/112> <http://example.com/id> "112"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/student/10> <http://example.com/plays> <http://example.com/sport/110> . <http://example.com/student/12> <http://example.com/plays> <http://example.com/sport/111> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/112> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/111> .
Title: M to M relation, by using an additional Triples Map
Description: Tests, M to M relations, by using an additional Triples Map (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student"; ]; rr:subjectMap [ rr:template "http://example.com/student/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "FirstName" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "LastName" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "sport"; ]; rr:subjectMap [ rr:template "http://example.com/sport/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate ex:description; rr:objectMap [ rml:reference "Description" ] ]. <LinkMap_1_2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "student_sport"; ]; rr:subjectMap [ rr:template "http://example.com/student/{ID_Student}"; ]; rr:predicateObjectMap [ rr:predicate ex:plays; rr:objectMap [ rr:template "http://example.com/sport/{ID_Sport}" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/student/10> <http://example.com/lastName> "Williams" . <http://example.com/student/10> <http://example.com/firstName> "Venus" . <http://example.com/student/12> <http://example.com/lastName> "Villa" . <http://example.com/student/12> <http://example.com/firstName> "David" . <http://example.com/student/11> <http://example.com/lastName> "Alonso" . <http://example.com/student/11> <http://example.com/firstName> "Fernando" . <http://example.com/sport/110> <http://example.com/description> "Tennis" . <http://example.com/sport/110> <http://example.com/id> "110"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/sport/111> <http://example.com/description> "Football" . <http://example.com/sport/111> <http://example.com/id> "111"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/sport/112> <http://example.com/description> "Formula1" . <http://example.com/sport/112> <http://example.com/id> "112"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/student/10> <http://example.com/plays> <http://example.com/sport/110> . <http://example.com/student/12> <http://example.com/plays> <http://example.com/sport/111> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/112> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/111> .
Title: M to M relation, by using an additional Triples Map
Description: Tests, M to M relations, by using an additional Triples Map
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/Students/Student" ]; rr:subjectMap [ rr:template "http://example.com/student/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "FirstName" ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "LastName" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "sport.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/Sports/Sport" ]; rr:subjectMap [ rr:template "http://example.com/sport/{ID}"; ]; rr:predicateObjectMap [ rr:predicate ex:id; rr:objectMap [ rml:reference "ID" ] ]; rr:predicateObjectMap [ rr:predicate ex:description; rr:objectMap [ rml:reference "Description" ] ]. <LinkMap_1_2> a rr:TriplesMap; rml:logicalSource [ rml:source "student_sport.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/links/link" ]; rr:subjectMap [ rr:template "http://example.com/student/{ID_Student}"; ]; rr:predicateObjectMap [ rr:predicate ex:plays; rr:objectMap [ rr:template "http://example.com/sport/{ID_Sport}" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/student/10> <http://example.com/lastName> "Williams" . <http://example.com/student/10> <http://example.com/firstName> "Venus" . <http://example.com/student/12> <http://example.com/lastName> "Villa" . <http://example.com/student/12> <http://example.com/firstName> "David" . <http://example.com/student/11> <http://example.com/lastName> "Alonso" . <http://example.com/student/11> <http://example.com/firstName> "Fernando" . <http://example.com/sport/110> <http://example.com/description> "Tennis" . <http://example.com/sport/110> <http://example.com/id> "110" . <http://example.com/sport/111> <http://example.com/description> "Football" . <http://example.com/sport/111> <http://example.com/id> "111" . <http://example.com/sport/112> <http://example.com/description> "Formula1" . <http://example.com/sport/112> <http://example.com/id> "112" . <http://example.com/student/10> <http://example.com/plays> <http://example.com/sport/110> . <http://example.com/student/12> <http://example.com/plays> <http://example.com/sport/111> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/112> . <http://example.com/student/11> <http://example.com/plays> <http://example.com/sport/111> .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "{fname}{lname}{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: No
Expected knowledge graph: (download)
_:BobSmith30 <http://example.com/amount> "30" . _:BobSmith30 <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones20 <http://example.com/amount> "20" . _:SueJones20 <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:subjectMap [ rr:template "{fname}{lname}{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: No
Expected knowledge graph: (download)
_:BobSmith30 <http://example.com/amount> "30" . _:BobSmith30 <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones20 <http://example.com/amount> "20" . _:SueJones20 <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith_30 <http://example.com/amount> "30"^^<http://www.w3.org/2001/XMLSchema#integer> . _:Bob_Smith_30 <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:Sue_Jones_20 <http://example.com/amount> "20"^^<http://www.w3.org/2001/XMLSchema#integer> . _:Sue_Jones_20 <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith_30 <http://example.com/amount> "30"^^<http://www.w3.org/2001/XMLSchema#integer> . _:Bob_Smith_30 <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:Sue_Jones_20 <http://example.com/amount> "20"^^<http://www.w3.org/2001/XMLSchema#integer> . _:Sue_Jones_20 <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith_30 <http://example.com/amount> "30"^^<http://www.w3.org/2001/XMLSchema#integer> . _:Bob_Smith_30 <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:Sue_Jones_20 <http://example.com/amount> "20"^^<http://www.w3.org/2001/XMLSchema#integer> . _:Sue_Jones_20 <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/Persons/Person" ]; rr:subjectMap [ rr:template "{fname}{lname}{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: No
Expected knowledge graph: (download)
_:BobSmith30 <http://example.com/amount> "30" . _:BobSmith30 <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones20 <http://example.com/amount> "20" . _:SueJones20 <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "lives.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate ex:city ; rr:objectMap [ rml:reference "city"; ] ]; .
Error expected: No
Expected knowledge graph: (download)
_:BobSmith <http://example.com/city> "London" . _:BobSmith <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones <http://example.com/city> "Madrid" . _:SueJones <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "lives.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.lives[*]" ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate ex:city ; rr:objectMap [ rml:reference "city"; ] ]; .
Error expected: No
Expected knowledge graph: (download)
_:BobSmith <http://example.com/city> "London" . _:BobSmith <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones <http://example.com/city> "Madrid" . _:SueJones <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "persons"; ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "lives"; ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate ex:city ; rr:objectMap [ rml:reference "city"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:BobSmith <http://example.com/city> "London" . _:BobSmith <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones <http://example.com/city> "Madrid" . _:SueJones <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "persons"; ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "lives"; ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate ex:city ; rr:objectMap [ rml:reference "city"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "password" .
Error expected: No
Expected knowledge graph: (download)
_:BobSmith <http://example.com/city> "London" . _:BobSmith <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones <http://example.com/city> "Madrid" . _:SueJones <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "persons"; ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "lives"; ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate ex:city ; rr:objectMap [ rml:reference "city"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
_:BobSmith <http://example.com/city> "London" . _:BobSmith <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones <http://example.com/city> "Madrid" . _:SueJones <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: Duplicate tuples generate same blank node
Description: Tests that blank nodes with same identifier and in the same graph but generated by different logical rows are considered equivalent. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/Persons/Person" ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode ; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "lives.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/Lives/Live" ]; rr:subjectMap [ rr:template "{fname}{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate ex:city ; rr:objectMap [ rml:reference "city"; ] ]; .
Error expected: No
Expected knowledge graph: (download)
_:BobSmith <http://example.com/city> "London" . _:BobSmith <http://xmlns.com/foaf/0.1/name> "Bob Smith" . _:SueJones <http://example.com/city> "Madrid" . _:SueJones <http://xmlns.com/foaf/0.1/name> "Sue Jones" .
Title: TriplesMap without subjectMap
Description: Tests a RML with missing information, TriplesMap without subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.csv"; rml:referenceFormulation ql:CSV ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap without subjectMap
Description: Tests a RML with missing information, TriplesMap without subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap without subjectMap
Description: Tests a RML with missing information, TriplesMap without subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap without subjectMap
Description: Tests a RML with missing information, TriplesMap without subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "password" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap without subjectMap
Description: Tests a RML with missing information, TriplesMap without subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap without subjectMap
Description: Tests a RML with missing information, TriplesMap without subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:XPath; rml:iterator "/Persons/Person" ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap with two subjectMap
Description: Tests a RML with wrong information, TriplesMap with two subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:subjectMap [ rr:template "{amount}_{fname}_{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap with two subjectMap
Description: Tests a RML with wrong information, TriplesMap with two subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:subjectMap [ rr:template "{amount}_{fname}_{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap with two subjectMap
Description: Tests a RML with wrong information, TriplesMap with two subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; ]; rr:subjectMap [ rr:template "{amount}_{fname}_{lname}"; ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap with two subjectMap
Description: Tests a RML with wrong information, TriplesMap with two subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; ]; rr:subjectMap [ rr:template "{amount}_{fname}_{lname}"; ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "password" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap with two subjectMap
Description: Tests a RML with wrong information, TriplesMap with two subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; ]; rr:subjectMap [ rr:template "{amount}_{fname}_{lname}"; ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: TriplesMap with two subjectMap
Description: Tests a RML with wrong information, TriplesMap with two subjectMap. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:XPath; rml:iterator "/Persons/Person" ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:subjectMap [ rr:template "{amount}_{fname}_{lname}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rr:template "{fname} {lname}"; rr:termType rr:Literal ; ] ]; rr:predicateObjectMap [ rr:predicate ex:amount ; rr:objectMap [ rml:reference "amount"; ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Default mapping
Description: Tests the generation of a default mapping for tables without a primary key. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object <IOUs>; ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname> ; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname> ; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#amount> ; rr:objectMap [ rml:reference "amount"; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Lives" ]; rr:subjectMap [ rr:template "{fname}_{lname}_{city}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object <Lives>; ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname> ; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname> ; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#city> ; rr:objectMap [ rml:reference "city"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith_30 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Bob_Smith_30 <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith_30 <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith_30 <http://example.com/base/IOUs#amount> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Sue_Jones_20 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Sue_Jones_20 <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones_20 <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones_20 <http://example.com/base/IOUs#amount> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Bob_Smith_London <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/Lives> . _:Bob_Smith_London <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith_London <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith_London <http://example.com/base/IOUs#city> "London" . _:Sue_Jones_Madrid <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/Lives> . _:Sue_Jones_Madrid <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones_Madrid <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones_Madrid <http://example.com/base/IOUs#city> "Madrid" .
Title: Default mapping
Description: Tests the generation of a default mapping for tables without a primary key. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object <IOUs>; ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname> ; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname> ; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#amount> ; rr:objectMap [ rml:reference "amount"; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Lives" ]; rr:subjectMap [ rr:template "{fname}_{lname}_{city}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object <Lives>; ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname> ; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname> ; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#city> ; rr:objectMap [ rml:reference "city"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith_30 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Bob_Smith_30 <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith_30 <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith_30 <http://example.com/base/IOUs#amount> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Sue_Jones_20 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Sue_Jones_20 <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones_20 <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones_20 <http://example.com/base/IOUs#amount> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Bob_Smith_London <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/Lives> . _:Bob_Smith_London <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith_London <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith_London <http://example.com/base/IOUs#city> "London" . _:Sue_Jones_Madrid <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/Lives> . _:Sue_Jones_Madrid <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones_Madrid <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones_Madrid <http://example.com/base/IOUs#city> "Madrid" .
Title: Default mapping
Description: Tests the generation of a default mapping for tables without a primary key. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "IOUs"; ]; rr:subjectMap [ rr:template "{fname}_{lname}_{amount}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object <IOUs>; ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname> ; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname> ; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#amount> ; rr:objectMap [ rml:reference "amount"; ] ]; . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Lives" ]; rr:subjectMap [ rr:template "{fname}_{lname}_{city}"; rr:termType rr:BlankNode; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object <Lives>; ]; rr:predicateObjectMap [ rr:predicate <IOUs#fname> ; rr:objectMap [ rml:reference "fname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#lname> ; rr:objectMap [ rml:reference "lname"; ] ]; rr:predicateObjectMap [ rr:predicate <IOUs#city> ; rr:objectMap [ rml:reference "city"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
_:Bob_Smith_30 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Bob_Smith_30 <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith_30 <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith_30 <http://example.com/base/IOUs#amount> "3.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Sue_Jones_20 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/IOUs> . _:Sue_Jones_20 <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones_20 <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones_20 <http://example.com/base/IOUs#amount> "2.0E1"^^<http://www.w3.org/2001/XMLSchema#double> . _:Bob_Smith_London <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/Lives> . _:Bob_Smith_London <http://example.com/base/IOUs#fname> "Bob" . _:Bob_Smith_London <http://example.com/base/IOUs#lname> "Smith" . _:Bob_Smith_London <http://example.com/base/IOUs#city> "London" . _:Sue_Jones_Madrid <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example.com/base/Lives> . _:Sue_Jones_Madrid <http://example.com/base/IOUs#fname> "Sue" . _:Sue_Jones_Madrid <http://example.com/base/IOUs#lname> "Jones" . _:Sue_Jones_Madrid <http://example.com/base/IOUs#city> "Madrid" .
Title: Null value in JSON file
Description: Tests if null values in JSON files are handled correctly.
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:subjectMap [ rr:template "http://example.com/Person/{ID}/{Name}/{DateOfBirth}"]; rr:predicateObjectMap [ rr:predicate ex:BirthDay ; rr:objectMap [ rml:reference "DateOfBirth" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Person/2/Bob/September%2C%202010> <http://example.com/BirthDay> "September, 2010" .
Title: Generation of empty triples from referenced columns that have null values
Description: Tests the generation of empty triples from referenced columns that have null values (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Person"; ]; rr:subjectMap [ rr:template "http://example.com/Person/{ID}/{Name}/{DateOfBirth}" ]; rr:predicateObjectMap [ rr:predicate ex:BirthDay ; rr:objectMap [ rr:reference "DateOfBirth"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; # this is ignored d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Person/2/Bob/September%2C%202010> <http://example.com/BirthDay> "September, 2010" .
Title: Generation of empty triples from referenced columns that have null values
Description: Tests the generation of empty triples from referenced columns that have null values (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Person"; ]; rr:subjectMap [ rr:template "http://example.com/Person/{id}/{name}/{DateOfBirth}" ]; rr:predicateObjectMap [ rr:predicate ex:BirthDay ; rr:objectMap [ rr:reference "DateOfBirth"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "password" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Person/2/Bob/September%2C%202010> <http://example.com/BirthDay> "September, 2010" .
Title: Generation of empty triples from referenced columns that have null values
Description: Tests the generation of empty triples from referenced columns that have null values (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Person"; ]; rr:subjectMap [ rr:template "http://example.com/Person/{ID}/{Name}/{DateOfBirth}" ]; rr:predicateObjectMap [ rr:predicate ex:BirthDay ; rr:objectMap [ rr:reference "DateOfBirth"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; # the "jbdc:mysql:// part is ignored d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Person/2/Bob/September%2C%202010> <http://example.com/BirthDay> "September, 2010" .
Title: three tables, one primary key, one foreign key
Description: Test the translation of database type codes to IRIs (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/ns#> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT EMP.*, (CASE job WHEN 'CLERK' THEN 'general-office' WHEN 'NIGHTGUARD' THEN 'security' WHEN 'ENGINEER' THEN 'engineering' END) AS ROLE FROM EMP """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://data.example.com/employee/{empno}" ]; rr:predicateObjectMap [ rr:predicate ex:role; rr:objectMap [ rr:template "http://data.example.com/roles/{ROLE}" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://data.example.com/employee/7369> <http://example.com/ns#role> <http://data.example.com/roles/general-office> .
Title: three tables, one primary key, one foreign key
Description: Test the translation of database type codes to IRIs (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/ns#> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT EMP.*, (CASE job WHEN 'CLERK' THEN 'general-office' WHEN 'NIGHTGUARD' THEN 'security' WHEN 'ENGINEER' THEN 'engineering' END) AS ROLE FROM EMP """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://data.example.com/employee/{empno}" ]; rr:predicateObjectMap [ rr:predicate ex:role; rr:objectMap [ rr:template "http://data.example.com/roles/{role}" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://data.example.com/employee/7369> <http://example.com/ns#role> <http://data.example.com/roles/general-office> .
Title: three tables, one primary key, one foreign key
Description: Test the translation of database type codes to IRIs (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/ns#> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT EMP.*, (CASE job WHEN 'CLERK' THEN 'general-office' WHEN 'NIGHTGUARD' THEN 'security' WHEN 'ENGINEER' THEN 'engineering' END) AS ROLE FROM EMP """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://data.example.com/employee/{empno}" ]; rr:predicateObjectMap [ rr:predicate ex:role; rr:objectMap [ rr:template "http://data.example.com/roles/{ROLE}" ]; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://data.example.com/employee/7369> <http://example.com/ns#role> <http://data.example.com/roles/general-office> .
Title: Generation of language tags from a table with language information
Description: Generation of language tags from a table with language information (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_en.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "en" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "country_es.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "es" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Bolivia, Plurinational State of"@en . <http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Estado Plurinacional de Bolivia"@es . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Ireland"@en . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Irlanda"@es .
Title: Generation of language tags from a table with language information
Description: Generation of language tags from a table with language information (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_en.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.countries[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "en" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "country_es.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.countries[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "es" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Bolivia, Plurinational State of"@en . <http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Estado Plurinacional de Bolivia"@es . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Ireland"@en . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Irlanda"@es .
Title: Generation of language tags from a table with language information
Description: Generation of language tags from a table with language information (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Code, Name, Lan FROM Country WHERE Lan = 'EN'; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "en" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT "Code", "Name", "Lan" FROM "Country" WHERE "Lan" = 'ES'; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "es" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Bolivia, Plurinational State of"@en . <http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Estado Plurinacional de Bolivia"@es . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Ireland"@en . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Irlanda"@es .
Title: Generation of language tags from a table with language information
Description: Generation of language tags from a table with language information (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Code, Name, Lan FROM Country WHERE Lan = 'EN'; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "name"; rr:language "en" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT "Code", "Name", "Lan" FROM "Country" WHERE "Lan" = 'ES'; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "name"; rr:language "es" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Bolivia, Plurinational State of"@en . <http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Estado Plurinacional de Bolivia"@es . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Ireland"@en . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Irlanda"@es .
Title: Generation of language tags from a table with language information
Description: Generation of language tags from a table with language information (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Code, Name, Lan FROM Country WHERE Lan = 'EN'; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "en" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT "Code", "Name", "Lan" FROM "Country" WHERE "Lan" = 'ES'; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "es" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Bolivia, Plurinational State of"@en . <http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Estado Plurinacional de Bolivia"@es . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Ireland"@en . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Irlanda"@es .
Title: Generation of language tags from a table with language information
Description: Generation of language tags from a table with language information (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_en.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/countries/country" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "en" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "country_es.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/countries/country" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "es" ] ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Bolivia, Plurinational State of"@en . <http://example.com/BO> <http://www.w3.org/2000/01/rdf-schema#label> "Estado Plurinacional de Bolivia"@es . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Ireland"@en . <http://example.com/IE> <http://www.w3.org/2000/01/rdf-schema#label> "Irlanda"@es .
Title: Generation of language tags from a table with language information, and a term map with invalid rr:language value
Description: Tests a term map with an invalid rr:language value, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_en.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label; rr:objectMap [ rml:reference "Name"; rr:language "english" ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "country_es.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label; rr:objectMap [ rml:reference "Name"; rr:language "spanish" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Generation of language tags from a table with language information, and a term map with invalid rr:language value
Description: Tests a term map with an invalid rr:language value, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_en.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.countries[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label; rr:objectMap [ rml:reference "Name"; rr:language "english" ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "country_en.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.countries[*]" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label; rr:objectMap [ rml:reference "Name"; rr:language "spanish" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Generation of language tags from a table with language information, and a term map with invalid rr:language value
Description: Tests a term map with an invalid rr:language value, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Code, Name, Lan FROM Country WHERE Lan = 'EN'; """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "english" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT "Code", "Name", "Lan" FROM "Country" WHERE "Lan" = 'ES'; """ ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "spanish" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Generation of language tags from a table with language information, and a term map with invalid rr:language value
Description: Tests a term map with an invalid rr:language value, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Code, Name, Lan FROM Country WHERE Lan = 'EN'; """ ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "english" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT "Code", "Name", "Lan" FROM "Country" WHERE "Lan" = 'ES'; """ ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "spanish" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Generation of language tags from a table with language information, and a term map with invalid rr:language value
Description: Tests a term map with an invalid rr:language value, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT Code, Name, Lan FROM Country WHERE Lan = 'EN'; """ ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "english" ] ]. <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT "Code", "Name", "Lan" FROM "Country" WHERE "Lan" = 'ES'; """ ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label ; rr:objectMap [ rml:reference "Name"; rr:language "spanish" ] ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Generation of language tags from a table with language information, and a term map with invalid rr:language value
Description: Tests a term map with an invalid rr:language value, which is an error (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "country_en.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/countries/country" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label; rr:objectMap [ rml:reference "Name"; rr:language "english" ] ] . <TriplesMap2> a rr:TriplesMap; rml:logicalSource [ rml:source "country_es.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/countries/country" ]; rr:subjectMap [ rr:template "http://example.com/{Code}" ]; rr:predicateObjectMap [ rr:predicate rdfs:label; rr:objectMap [ rml:reference "Name"; rr:language "spanish" ] ].
Error expected: Yes
Expected knowledge graph: None, because an error is expected that stops the generation.
Title: Table with datatypes: string and integer
Description: Tests the rr:termtype and datatype conversions: string and integer (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient/{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "FirstName"; ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "LastName"; ] ]; rr:predicateObjectMap [ rr:predicate ex:gender; rr:objectMap [ rml:reference "Sex"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient/10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/10> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/10> <http://example.com/firstName> "Monica" . <http://example.com/Patient/10> <http://example.com/lastName> "Geller" . <http://example.com/Patient/10> <http://example.com/gender> "female" . <http://example.com/Patient/11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/11> <http://example.com/id> "11"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/11> <http://example.com/firstName> "Rachel" . <http://example.com/Patient/11> <http://example.com/lastName> "Green" . <http://example.com/Patient/11> <http://example.com/gender> "female" . <http://example.com/Patient/12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/12> <http://example.com/id> "12"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/12> <http://example.com/firstName> "Chandler" . <http://example.com/Patient/12> <http://example.com/lastName> "Bing" . <http://example.com/Patient/12> <http://example.com/gender> "male" .
Title: Table with datatypes: string and integer
Description: Tests the rr:termtype and datatype conversions: string and integer (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient/{id}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "id"; ] ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "firstname"; ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "lastname"; ] ]; rr:predicateObjectMap [ rr:predicate ex:gender; rr:objectMap [ rml:reference "sex"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient/10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/10> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/10> <http://example.com/firstName> "Monica" . <http://example.com/Patient/10> <http://example.com/lastName> "Geller" . <http://example.com/Patient/10> <http://example.com/gender> "female" . <http://example.com/Patient/11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/11> <http://example.com/id> "11"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/11> <http://example.com/firstName> "Rachel" . <http://example.com/Patient/11> <http://example.com/lastName> "Green" . <http://example.com/Patient/11> <http://example.com/gender> "female" . <http://example.com/Patient/12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/12> <http://example.com/id> "12"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/12> <http://example.com/firstName> "Chandler" . <http://example.com/Patient/12> <http://example.com/lastName> "Bing" . <http://example.com/Patient/12> <http://example.com/gender> "male" .
Title: Table with datatypes: string and integer
Description: Tests the rr:termtype and datatype conversions: string and integer (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient/{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate ex:firstName; rr:objectMap [ rml:reference "FirstName"; ] ]; rr:predicateObjectMap [ rr:predicate ex:lastName; rr:objectMap [ rml:reference "LastName"; ] ]; rr:predicateObjectMap [ rr:predicate ex:gender; rr:objectMap [ rml:reference "Sex"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient/10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/10> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/10> <http://example.com/firstName> "Monica" . <http://example.com/Patient/10> <http://example.com/lastName> "Geller" . <http://example.com/Patient/10> <http://example.com/gender> "female" . <http://example.com/Patient/11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/11> <http://example.com/id> "11"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/11> <http://example.com/firstName> "Rachel" . <http://example.com/Patient/11> <http://example.com/lastName> "Green" . <http://example.com/Patient/11> <http://example.com/gender> "female" . <http://example.com/Patient/12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient/12> <http://example.com/id> "12"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/Patient/12> <http://example.com/firstName> "Chandler" . <http://example.com/Patient/12> <http://example.com/lastName> "Bing" . <http://example.com/Patient/12> <http://example.com/gender> "male" .
Title: Table with datatypes: real and float
Description: Tests the rr:termtype and datatype conversions: real and float (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:weight; rr:objectMap [ rml:reference "Weight"; ] ]; rr:predicateObjectMap [ rr:predicate ex:height; rr:objectMap [ rml:reference "Height"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/weight> "8.025E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient10> <http://example.com/height> "1.65E0"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/weight> "7.022E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient11> <http://example.com/height> "1.7E0"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/weight> "9.031E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient12> <http://example.com/height> "1.76E0"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Table with datatypes: real and float
Description: Tests the rr:termtype and datatype conversions: real and float (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{id}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:weight; rr:objectMap [ rml:reference "weight"; ] ]; rr:predicateObjectMap [ rr:predicate ex:height; rr:objectMap [ rml:reference "height"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/weight> "8.025E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient10> <http://example.com/height> "1.65E0"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/weight> "7.022E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient11> <http://example.com/height> "1.7E0"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/weight> "9.031E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient12> <http://example.com/height> "1.76E0"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Table with datatypes: real and float
Description: Tests the rr:termtype and datatype conversions: real and float (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:weight; rr:objectMap [ rml:reference "Weight"; ] ]; rr:predicateObjectMap [ rr:predicate ex:height; rr:objectMap [ rml:reference "Height"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/weight> "8.025E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient10> <http://example.com/height> "1.65E0"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/weight> "7.022E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient11> <http://example.com/height> "1.7E0"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/weight> "9.031E1"^^<http://www.w3.org/2001/XMLSchema#double> . <http://example.com/Patient12> <http://example.com/height> "1.76E0"^^<http://www.w3.org/2001/XMLSchema#double> .
Title: Table with datatypes: date and timestamp
Description: Tests the rr:termtype and datatype conversions: date and timestamp (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:birthdate; rr:objectMap [ rml:reference "BirthDate"; ] ]; rr:predicateObjectMap [ rr:predicate ex:entrancedate; rr:objectMap [ rml:reference "EntranceDate"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/birthdate> "1981-10-10"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient10> <http://example.com/entrancedate> "2009-10-10T12:12:22"^^<http://www.w3.org/2001/XMLSchema#dateTime> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/birthdate> "1982-11-12"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient11> <http://example.com/entrancedate> "2008-11-12T09:45:44"^^<http://www.w3.org/2001/XMLSchema#dateTime> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/birthdate> "1978-04-06"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient12> <http://example.com/entrancedate> "2007-03-12T02:13:14"^^<http://www.w3.org/2001/XMLSchema#dateTime> .
Title: Table with datatypes: date and timestamp
Description: Tests the rr:termtype and datatype conversions: date and timestamp (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{id}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:birthdate; rr:objectMap [ rml:reference "birthdate"; ] ]; rr:predicateObjectMap [ rr:predicate ex:entrancedate; rr:objectMap [ rml:reference "entrancedate"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/birthdate> "1981-10-10"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient10> <http://example.com/entrancedate> "2009-10-10T12:12:22"^^<http://www.w3.org/2001/XMLSchema#dateTime> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/birthdate> "1982-11-12"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient11> <http://example.com/entrancedate> "2008-11-12T09:45:44"^^<http://www.w3.org/2001/XMLSchema#dateTime> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/birthdate> "1978-04-06"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient12> <http://example.com/entrancedate> "2007-03-12T02:13:14"^^<http://www.w3.org/2001/XMLSchema#dateTime> .
Title: Table with datatypes: date and timestamp
Description: Tests the rr:termtype and datatype conversions: date and timestamp (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:birthdate; rr:objectMap [ rml:reference "BirthDate"; ] ]; rr:predicateObjectMap [ rr:predicate ex:entrancedate; rr:objectMap [ rml:reference "EntranceDate"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/birthdate> "1981-10-10"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient10> <http://example.com/entrancedate> "2009-10-10T12:12:22"^^<http://www.w3.org/2001/XMLSchema#dateTime> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/birthdate> "1982-11-12"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient11> <http://example.com/entrancedate> "2008-11-12T09:45:44"^^<http://www.w3.org/2001/XMLSchema#dateTime> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/birthdate> "1978-04-06"^^<http://www.w3.org/2001/XMLSchema#date> . <http://example.com/Patient12> <http://example.com/entrancedate> "2007-03-12T02:13:14"^^<http://www.w3.org/2001/XMLSchema#dateTime> .
Title: Table with datatypes, boolean conversions
Description: Tests the rr:termtype and datatype conversions: boolean (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:paid; rr:objectMap [ rml:reference "PaidInAdvance"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/paid> "false"^^<http://www.w3.org/2001/XMLSchema#boolean> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/paid> "true"^^<http://www.w3.org/2001/XMLSchema#boolean> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/paid> "true"^^<http://www.w3.org/2001/XMLSchema#boolean> .
Title: Table with datatypes, boolean conversions
Description: Tests the rr:termtype and datatype conversions: boolean (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{id}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:paid; rr:objectMap [ rml:reference "paidinadvance"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/paid> "false"^^<http://www.w3.org/2001/XMLSchema#boolean> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/paid> "true"^^<http://www.w3.org/2001/XMLSchema#boolean> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/paid> "true"^^<http://www.w3.org/2001/XMLSchema#boolean> .
Title: Table with datatypes, boolean conversions
Description: Tests the rr:termtype and datatype conversions: boolean (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:paid; rr:objectMap [ rml:reference "PaidInAdvance"; ] ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/paid> "false"^^<http://www.w3.org/2001/XMLSchema#boolean> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/paid> "true"^^<http://www.w3.org/2001/XMLSchema#boolean> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/paid> "true"^^<http://www.w3.org/2001/XMLSchema#boolean> .
Title: Table with datatypes, binary column
Description: Tests the rr:termtype and datatype conversions: binary (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:photo; rr:objectMap [ rr:template "data:image/png;hex,{Photo}"; ]; ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFEBFC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFF3FC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFEBFC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> .
Title: Table with datatypes, binary column
Description: Tests the rr:termtype and datatype conversions: binary (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{id}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:photo; rr:objectMap [ rr:template "data:image/png;hex,{photo}"; ]; ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFEBFC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFF3FC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFEBFC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> .
Title: Table with datatypes, binary column
Description: Tests the rr:termtype and datatype conversions: binary (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Patient" ]; rr:subjectMap [ rr:template "http://example.com/Patient{ID}"; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]; rr:predicateObjectMap [ rr:predicate ex:photo; rr:objectMap [ rr:template "data:image/png;hex,{Photo}"; ]; ]; . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/Patient10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient10> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFEBFC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> . <http://example.com/Patient11> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient11> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFF3FC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> . <http://example.com/Patient12> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/Patient12> <http://example.com/photo> <data:image/png;hex,89504E470D0A1A0A0000000D49484452000000050000000508060000008D6F26E50000001C4944415408D763F9FFFEBFC37F062005C3201284D031F18258CD04000EF535CBD18E0E1F0000000049454E44AE426082> .
Title: Generation of triples by using CHAR datatype column
Description: Generation of triples by using CHAR datatype column, resulting RDF literal is space-padded. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}"; rr:class foaf:Person]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10> <http://xmlns.com/foaf/0.1/name> "Venus " . <http://example.com/10> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/20> <http://xmlns.com/foaf/0.1/name> "Fernando " . <http://example.com/20> <http://example.com/id> "20"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/30> <http://xmlns.com/foaf/0.1/name> "David " . <http://example.com/30> <http://example.com/id> "30"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/30> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using CHAR datatype column
Description: Generation of triples by using CHAR datatype column, resulting RDF literal is space-padded. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "http://example.com/{id}"; rr:class foaf:Person]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "id"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10> <http://xmlns.com/foaf/0.1/name> "Venus " . <http://example.com/10> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/20> <http://xmlns.com/foaf/0.1/name> "Fernando " . <http://example.com/20> <http://example.com/id> "20"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/30> <http://xmlns.com/foaf/0.1/name> "David " . <http://example.com/30> <http://example.com/id> "30"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/30> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using CHAR datatype column
Description: Generation of triples by using CHAR datatype column, resulting RDF literal is space-padded. (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "http://example.com/{ID}"; rr:class foaf:Person]; rr:predicateObjectMap [ rr:predicate ex:id ; rr:objectMap [ rml:reference "ID"; ] ]; rr:predicateObjectMap [ rr:predicate foaf:name ; rr:objectMap [ rml:reference "Name" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/10> <http://xmlns.com/foaf/0.1/name> "Venus " . <http://example.com/10> <http://example.com/id> "10"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/10> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/20> <http://xmlns.com/foaf/0.1/name> "Fernando " . <http://example.com/20> <http://example.com/id> "20"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/20> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/30> <http://xmlns.com/foaf/0.1/name> "David " . <http://example.com/30> <http://example.com/id> "30"^^<http://www.w3.org/2001/XMLSchema#integer> . <http://example.com/30> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in attributes
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT ID, FirstName, LastName FROM Employee WHERE ID < 30 """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT ID, FirstName, LastName FROM Employee WHERE ID < 30 """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "firstname" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "firstname" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rml:query """ SELECT ID, FirstName, LastName FROM Employee WHERE ID < 30 """ ; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in elements
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/persons/person" ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns, with data error
Description: Test the generation of triples by using IRI value in columns, conforming RML mapping with data error (and limited results)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns, with data error
Description: Test the generation of triples by using IRI value in attributes, conforming RML mapping with data error (and limited results)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.persons[*]" ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns, with data error
Description: Test the generation of triples by using IRI value in columns, conforming RML mapping with data error (and limited results) (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Employee" ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns, with data error
Description: Test the generation of triples by using IRI value in columns, conforming RML mapping with data error (and limited results) (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Employee" ]; rr:subjectMap [ rml:reference "firstname" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "firstname" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns, with data error
Description: Test the generation of triples by using IRI value in columns, conforming RML mapping with data error (and limited results) (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Employee" ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] . <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns, with data error
Description: Test the generation of triples by using IRI value in elements, conforming RML mapping with data error (and limited results)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "persons.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/persons/person" ]; rr:subjectMap [ rml:reference "FirstName" ]; rr:predicateObjectMap [ rr:predicate foaf:name; rr:objectMap [ rml:reference "FirstName" ] ] .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/ns#Jhon> <http://xmlns.com/foaf/0.1/name> "http://example.com/ns#Jhon" . <http://example.com/base/Carlos> <http://xmlns.com/foaf/0.1/name> "Carlos" .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:IRI ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/http%3A%2F%2Fexample.com%2Fcompany%2FAlice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob%2FCharles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path%2F..%2FDanny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Emily%20Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in attributes (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:IRI ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/http%3A%2F%2Fexample.com%2Fcompany%2FAlice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob%2FCharles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path%2F..%2FDanny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Emily%20Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/http%3A%2F%2Fexample.com%2Fcompany%2FAlice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob%2FCharles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path%2F..%2FDanny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Emily%20Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "{name}"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "password" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/http%3A%2F%2Fexample.com%2Fcompany%2FAlice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob%2FCharles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path%2F..%2FDanny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Emily%20Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in columns (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/http%3A%2F%2Fexample.com%2Fcompany%2FAlice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob%2FCharles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path%2F..%2FDanny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Emily%20Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns
Description: Test the generation of triples by using IRI value in elements (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rr:template "{Name}"; rr:termType rr:IRI ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/http%3A%2F%2Fexample.com%2Fcompany%2FAlice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob%2FCharles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path%2F..%2FDanny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Emily%20Smith> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns, with data errors
Description: Test the generation of triples by using IRI value in columns, conforming R2RML mapping with data error (and no result)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.csv"; rml:referenceFormulation ql:CSV ]; rr:subjectMap [ rml:reference "Name"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/Bob/Charles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/company/Alice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path/../Danny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns, with data errors
Description: Test the generation of triples by using IRI value in columns, conforming R2RML mapping with data error (and no result)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.json"; rml:referenceFormulation ql:JSONPath; rml:iterator "$.students[*]" ]; rr:subjectMap [ rml:reference "Name"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/Bob/Charles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/company/Alice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path/../Danny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns, with data errors
Description: Test the generation of triples by using IRI value in columns, conforming R2RML mapping with data error (and no result) (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rml:reference "Name"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.mysql.cj.jdbc.Driver"; d2rq:username "root"; d2rq:password "" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/Bob/Charles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/company/Alice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path/../Danny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns, with data errors
Description: Test the generation of triples by using IRI value in columns, conforming R2RML mapping with data error (and no result) (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rml:reference "name"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "org.postgresql.Driver"; d2rq:username "postgres"; d2rq:password "password" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/Bob/Charles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/company/Alice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path/../Danny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns, with data errors
Description: Test the generation of triples by using IRI value in columns, conforming R2RML mapping with data error (and no result) (specification reference)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source <#DB_source>; rr:sqlVersion rr:SQL2008; rr:tableName "Student" ]; rr:subjectMap [ rml:reference "Name"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ]. <#DB_source> a d2rq:Database; d2rq:jdbcDSN "CONNECTIONDSN"; d2rq:jdbcDriver "com.microsoft.sqlserver.jdbc.SQLServerDriver"; d2rq:username "sa"; d2rq:password "YourSTRONG!Passw0rd;" .
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/Bob/Charles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/company/Alice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path/../Danny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
Title: Generation of triples by using IRI value in columns, with data errors
Description: Test the generation of triples by using IRI value in columns, conforming R2RML mapping with data error (and no result)
RML rules (download):
@prefix rr: <http://www.w3.org/ns/r2rml#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . @prefix ex: <http://example.com/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix rml: <http://semweb.mmlab.be/ns/rml#> . @prefix ql: <http://semweb.mmlab.be/ns/ql#> . @base <http://example.com/base/> . <TriplesMap1> a rr:TriplesMap; rml:logicalSource [ rml:source "student.xml"; rml:referenceFormulation ql:XPath; rml:iterator "/students/student" ]; rr:subjectMap [ rml:reference "Name"; rr:termType rr:IRI; ]; rr:predicateObjectMap [ rr:predicate rdf:type; rr:object foaf:Person; ].
Error expected: No
Expected knowledge graph: (download)
<http://example.com/base/Bob/Charles> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/Bob> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/company/Alice> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> . <http://example.com/base/path/../Danny> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .