-
Notifications
You must be signed in to change notification settings - Fork 62
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
IDLabFunctions: use correct date pattern for normalizeDate
normalizeDate outputs the minutes of a date instead of the months. Use 'MMMM' instead of 'mm' when normalizing dates.
- Loading branch information
1 parent
5ff33f8
commit 1809b54
Showing
17 changed files
with
450 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
ID,INPUT,PATTERN | ||
0,20220124,yyyyMMdd | ||
1,01-Apr-20,dd-MMM-yy |
47 changes: 47 additions & 0 deletions
47
src/test/resources/rml-fno-test-cases/RMLFNOTCF009/mapping.ttl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
@prefix rr: <http://www.w3.org/ns/r2rml#> . | ||
@prefix ex: <http://example.com/> . | ||
@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 fnml: <http://semweb.mmlab.be/ns/fnml#> . | ||
@prefix fno: <https://w3id.org/function/ontology#> . | ||
@prefix grel: <http://users.ugent.be/~bjdmeest/function/grel.ttl#> . | ||
@prefix idlab-fn: <http://example.com/idlab/function/> . | ||
|
||
@base <http://example.com/base/> . | ||
|
||
<TriplesMap1> | ||
a rr:TriplesMap; | ||
|
||
rml:logicalSource [ | ||
rml:source "data.csv"; | ||
rml:referenceFormulation ql:CSV | ||
]; | ||
|
||
rr:subjectMap [ | ||
rr:template "http://example.com/{ID}" | ||
]; | ||
|
||
rr:predicateObjectMap [ | ||
|
||
rr:predicate ex:createdAt; | ||
|
||
rr:objectMap [ | ||
fnml:functionValue [ | ||
rr:predicateObjectMap [ | ||
rr:predicate fno:executes ; | ||
rr:objectMap [ rr:constant idlab-fn:normalizeDate ] | ||
]; | ||
|
||
rr:predicateObjectMap [ | ||
rr:predicate idlab-fn:strDate ; | ||
rr:objectMap [ rml:reference "INPUT" ] | ||
]; | ||
|
||
rr:predicateObjectMap [ | ||
rr:predicate idlab-fn:pattern ; | ||
rr:objectMap [ rml:reference "PATTERN" ] | ||
]; | ||
] | ||
] | ||
]. |
2 changes: 2 additions & 0 deletions
2
src/test/resources/rml-fno-test-cases/RMLFNOTCF009/output.ttl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<http://example.com/0> <http://example.com/createdAt> "2022-01-24" . | ||
<http://example.com/1> <http://example.com/createdAt> "2020-04-01" . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
ID,INPUT,PATTERN,LANG | ||
0,20220124,yyyyMMdd,en | ||
1,01-Apr-20,dd-MMM-yy,en | ||
2,01-avr.-20,dd-MMM-yy,fr |
Oops, something went wrong.