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
This is a continuation of the issue #67 in my opinion.
I tried out the solution provided by @pheyvaer along with the sample data on that issue using Matey and the output linked data seems off and might not have been what the original poster was probably looking for. I was expecting ex:Smith_Bland to only be associated with ex:John, but the solution with the equal function does not seem the right match.
I would like to know if there are more examples and documentation for parsing nested JSON structures, because I clicked through a few of the examples inside /yarrrml-parser/test, but I don't know which might be the correct one to follow.
Also, I have seen the list of RMLMapper functions. Where can I look for examples of how these are used inside YARRRML?
Coming to the problem at hand, I have a nested JSON object that has the following structure and I would like to:
Get the following data under report-content and assign it to the data property of an instance of class Requirement.
id
requirement_text
priority
Get the data in the JSON path $.report_content[*].additional_identifiers[1] and continue to assign this information to the appropriate data property in the corresponding instance of class Requirement.
name
type
url
I would be grateful for your help and suggestions. Thanks in advance! :-)
{
"report-content": [
{
"category": "requirement",
"id": "REQ-001",
"additional_identifiers": [
{
"name": "PersonXYZ",
"type": "Customer Representative",
"stakeholders": "EntityA"
},
{
"name": "Label for REQ-001",
"type": "Customer Requirement",
"url": "https://somelinkToRequirementsManagementTool.com"
}
],
"requirement_text": "This is a dummy requirement that is needed for some reason.",
"priority": "High"
},
{
"category": "requirement",
"id": "REQ-002",
"additional_identifiers": [
{
"name": "PersonABC",
"type": "Customer Representative",
"stakeholders": "EntityA, EntityB"
},
{
"name": "Label for REQ-002",
"type": "Customer Requirement",
"url": "https://somelinkToRequirementsManagementTool.com"
}
],
"requirement_text": "This is a dummy requirement that is needed for some reason.",
"priority": "Medium"
}
]
}
The text was updated successfully, but these errors were encountered:
An idea that is forming in my head is to use function nesting. First split the string data array within additional_identifiers, then find the second instance starting with name and get its value.
Is that a good approach? Or am I missing something very basic?
Issue type: ❓ Question
This is a continuation of the issue #67 in my opinion.
I tried out the solution provided by @pheyvaer along with the sample data on that issue using Matey and the output linked data seems off and might not have been what the original poster was probably looking for. I was expecting
ex:Smith_Bland
to only be associated withex:John
, but the solution with theequal
function does not seem the right match.I would like to know if there are more examples and documentation for parsing nested JSON structures, because I clicked through a few of the examples inside /yarrrml-parser/test, but I don't know which might be the correct one to follow.
Also, I have seen the list of RMLMapper functions. Where can I look for examples of how these are used inside YARRRML?
Coming to the problem at hand, I have a nested JSON object that has the following structure and I would like to:
report-content
and assign it to the data property of an instance of classRequirement
.id
requirement_text
priority
$.report_content[*].additional_identifiers[1]
and continue to assign this information to the appropriate data property in the corresponding instance of classRequirement
.name
type
url
I would be grateful for your help and suggestions. Thanks in advance! :-)
The text was updated successfully, but these errors were encountered: