bill_sturdivant
7 years agoNew Contributor III
Substring a field inside of an array?
I’m trying to substring the field $studySiteChecklist.checklist.lastUpdateDate but I can get it to keep the same output as the input.
Any ideas?
[{
"country": "a",
"studySiteChecklist": {
"checklist": [{
"lastUpdateDate": "2017-08-27T00:00:00Z",
"commentsIndicator": "0",
"comments": "0",
"yesNoIndicator": "0",
"questionNumber": "0",
"checkListNumer": "0",
"question": "0"
}, {
"lastUpdateDate": "2000-08-27T00:00:00Z",
"commentsIndicator": "0",
"comments": "0",
"yesNoIndicator": "0",
"questionNumber": "0",
"checkListNumer": "0",
"question": "0"
}]
}
}]
Output needed:
[{
"country": "a",
"studySiteChecklist": {
"checklist": [{
"lastUpdateDate": "2017-08-27",
"commentsIndicator": "0",
"comments": "0",
"yesNoIndicator": "0",
"questionNumber": "0",
"checkListNumer": "0",
"question": "0"
}, {
"lastUpdateDate": "2000-08-27",
"commentsIndicator": "0",
"comments": "0",
"yesNoIndicator": "0",
"questionNumber": "0",
"checkListNumer": "0",
"question": "0"
}]
}
}]