How to extract random json array from json data?

Using Deserialize JSON activity i get the output, I am using for each activity and loop through all the child arrays. From that how do i get the array data randomly each time from the json array.

Regards,
Manikandan Thangaraj

Check this…!

I have a name value pair as mentioned below

“patterns”: [“Hi”, “How are you”, “Is anyone there?”, “Hello”, “Good day”, “Whats up”].

How to pick the random value from the list ?

Thanks,
Manikandan

If you deserialize the above JSON, you need to use the key patterns to get the list of items @Manikandan.T

Okay, I am getting all values in key patterns I need only one value that should pick value randomly.

Regards,
Manikandan Thangaraj

As you will get the array or list from the key patterns, you need to pass the index to get the value. You can pass the random value by generating it.

1 Like