cancel
Showing results for 
Search instead for 
Did you mean: 

How to extract First Array value from Nested JSON Collection

kirtish.trivedi
Level 5

Hi Team , 

I need to convert JSON to CSV. for this I am first converting JSON to collection using JSON to collection(Skipping JArray) but I am getting output like below

I basically need 3 columns for csv output : host, included and Instance

I dont have issue in getting host and included but for instance, sometimes it has single value and sometime it has multiple in array

I need instance column value ( If it has multiple values, it should fetch first value) . 

Could you please help in extracting first value of instance from below collection ? 

Output

host ,included, instances[0]

18791.png



------------------------------
Kirtish Trivedi
------------------------------
0 REPLIES 0