You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I'm trying to use the null function to check the non-existence of a json entity in my data , but it is not behaving correctly:
My data is as follows: [{"id":"0","labels":["Student"],"properties":{"id":20}},{"type":"stay","id":"1","labels":["Sport"],"properties":{"sport_id":100,"sport_name":"Tennis"}},{"type":"node","id":"2","labels":["Student"],"properties":{"name":"Venus Williams","id":10,"sport":100}}]
Hello All,
So I'm trying to use the null function to check the non-existence of a json entity in my data , but it is not behaving correctly:
My data is as follows:
[{"id":"0","labels":["Student"],"properties":{"id":20}},{"type":"stay","id":"1","labels":["Sport"],"properties":{"sport_id":100,"sport_name":"Tennis"}},{"type":"node","id":"2","labels":["Student"],"properties":{"name":"Venus Williams","id":10,"sport":100}}]
and my mappings are the following:
prefixes:
rr: http://www.w3.org/ns/r2rml#
foaf: http://xmlns.com/foaf/0.1/
xsd: http://www.w3.org/2001/XMLSchema#
rdfs: http://www.w3.org/2000/01/rdf-schema#
Airport: http://example.org/Airport/
ontology: http://data.sfgov.org/ontology/
grel: http://users.ugent.be/~bjdmeest/function/grel.ttl#
exfunc: http://example.com/idlab/function/
ex: http://www.example.org/
idlab-fn: https://w3id.org/imec/idlab/function#`
mappings:
episode:
sources:
- [data.json~jsonpath, "$.[*]"]
s: ex:$(id)
condition:
function: idlab-fn:isNull
parameters:
- [grel:valueParameter, $(type)]
po:
- p: a
o: ex:Node
The output is:
<http://www.example.org/0> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.example.org/Node> . <http://www.example.org/1> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.example.org/Node> . <http://www.example.org/2> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.example.org/Node> .
while the expected output should return only the first triple
Also, is there any way to use the not null function as well in RML?
Best regards,
Ali.
The text was updated successfully, but these errors were encountered: