Parsing a JSON string to an object
Posted: Mon Aug 07, 2023 8:11 am
Hello,
i have a question about how to parse JSON string. The data I obtained from the api is as follows
I need to get all of his occupations from the string type JSON array field. How can I do that? Thanks.
i have a question about how to parse JSON string. The data I obtained from the api is as follows
Code: Select all
{
"name": "Andy",
"occupation": "[{"id": 1, "name": "Teacher"}, {"id": 2, "name": "doorkeeper"}]"
}