Not Exit from a loop
Hi to all!
i have got this loop on a formula:
Copy
it extract data from a Json like this:
i am trying to extract the first resource_url found independently if "primary" or "secondary" (but it has to be the first), but for some reason I can not understand the formula doesn't break the loop at the first resource_url found and the output got is the last:
3 replies
-
If you only need the first item in the array you should just use the item() function.
The only for-loop style you can break out of is this one and you do it by changing the value of i.
-
i had to "reParse" the JSON to use the item function.
And this:
let images := text(response.result.images);
let images := parseJSON(images);
let coverimageLink := item(images, 0).resource_url;
coverimage := coverimageLinkworks in an excellent way
THANK YOU a lot Sean
Content aside
- Status Answered
- 1 yr agoFri, October 6, 2023 at 12:16 PM UTCLast active
- 3Replies
- 124Views
-
2
Following