Open simeonackermann opened 3 years ago
Hello Unfortunately yarrrml conditions are currently not supported. In RML they transform to nested functions, which aren't supported. Only yarrrml join-conditions are supported (since they are a special condition case)
If the only condition you need is to check if a field is set you can use the json-path filter feature (see https://www.npmjs.com/package/jsonpath-plus for json-path examples)
With your current mapping:
prefixes:
schema: "http://schema.org/"
fn: "http://example.com/"
mappings:
person:
sources:
- ['input~jsonpath', '$.persons[?(@.public)]']
s: http://example.com/$(firstname)
po:
- [a, schema:Person]
will only process the persons where the public field is truthy. (so skip any persons with "public": false
or without any public field)
Ok thanks, its not that clear like YARRRML subject conditions, but it will solve may problem. Thanks again for your time and solution!!
Are their plans to implement nested functions? Does it make sense to leave this issue open?
I'm trying to apply a YARRRML Condition in the subject. It should only create a subject on a specific condition, but the parser throws an
???
error from input-parser/parser.js. It seems the termType rr:IRI in subjectMaps are not (yet) supported?!An example mapping to reproduce this error is:
Is there another way to apply conditions on subject generation?