Closed pabloalarconm closed 10 months ago
Hi!
I think you need to put on a mapping level for subjects, see https://rml.io/yarrrml/spec/#conditions
Closing as assumed resolved since no response for several months. Please re-open if you still have issues with this. Thanks!
Hi!
I'm trying to create a YARRRML template that contains a condition in which: if the data source column named
value_id
in the CSV contains "null" as value in the data cell, create a URL based on other columns like: this:$(pid)_$(uniqid)_Output. If it does not contain "null", use this value (it will be a URL) from thisvalue_id
column.The solution I found was to use functions
equal
andidlab-fn:notEqual
. This solution seems to work perfectly atpredicateobjects
every time I want to perform this function atobjects
. But, this function seems not to work withsubjects
. Based on the documentation,subjects
accepts bothfunctions
,value
andparameters
(ref and ref2), so it seems it should work in my case, but it doesnt.I will send you two YARRRML template and one CSV that fits with both templates. Each template contains the functions in different places: yarrrml_1.yaml has the functions at the
predicateobjects
and works, the second template, yarrrml_2.yaml contains the same functions in thesubjects
and doesn't work.Could you tell what changes do I need in yarrrml_2 to obtain same functionality but in
subjects
and I achieved in yarrrml_1 for `predicateobjects? Thank you so much, truly appreciated.yarrrml_1
yarrrml_2
data.csv
Results obtained from
yarrrml_1
anddata.csv