oeg-upm / mapeathor

Translator of spreadsheet mappings into R2RML, RML or YARRRML
https://morph.oeg.fi.upm.es/tool/mapeathor
Apache License 2.0
30 stars 10 forks source link

DataType for result of Function is ignored? #38

Open mnieuwland opened 2 years ago

mnieuwland commented 2 years ago

When I define the DataType to be of type 'iri', this seems to be ignored for the result of a Function.

In the Predicate_Object sheet: Predicate Object DataType
rdf:type \ iri

The generated RML mapping looks something like:

<#Function1>
    a rr:TriplesMap;
    a fnml:FunctionTermMap;

    fnml:functionValue [ ....

The result when using RMLMapper is a triple that looks like: \ a "http://example.com/uri"

I would expect: \ a

When I manually add rr:termType rr:IRI to the RML mapping I do get the desired triple

<#Function1>
    a rr:TriplesMap;
    a fnml:FunctionTermMap;
    rr:termType rr:IRI;

    fnml:functionValue [ ....
anaigmo commented 2 years ago

Solved in v1.5.4

mnieuwland commented 2 years ago

Thanks for solving this. Hower, now it seems that the Function always gets the datatype IRI.

So, when I have a Predicate_Object tab like this: Predicate Object DataType
time:inXSDDate \ date

The resulting RML looks like:

<#DateReformat>
    a rr:TriplesMap;
    a fnml:FunctionTermMap;
    rr:termType rr:IRI;

I would expect:

<#DateReformat>
    a rr:TriplesMap;
    a fnml:FunctionTermMap;
    rr:datatype xsd:date;