Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
PeterS3
Contributor
Contributor

tExtractJsonFields : java.io.IOException: Already in an array

Hello,

I try to read a json response with a tExtractJsonFields, and got this error : java.io.IOException: Already in an array

My json :

{

   "CollectionsContainer": [

       [

           {

               "__type": "AccessProfile:Alcea.WebServices(www.alcea.fr)",

               "AccessProfileID": 475,

               "BackTime": null,

               "Description": "xxxxx",

               "Disabled": false,

               "Name": "1234",

               "PassBack": false,

               "SupervisorCodeID": 31,

               "ValidityBeginDate": "2021-01-01",

               "ValidityEnddate": "2021-12-31",

               "PeriodCollection": null

           }

       ]

   ],

   "PageNumber": 1,

   "PageSize": 1,

   "ProcessingTime": "PT0.0312523S",

   "TotalNumber": 11,

   "TotalNumberRequest": 1,

   "success": true,

   "OperationResult": {

       "Status": "ALWIN_SDK_OK",

       "Message": null,

       "SystemMessage": null,

       "StackTrace": null

   }

}

I want to recup the field : AccessProfileID

I try a lot of things like that :

0695b00000DuuasAAB.png

but got this error with all my attempts.

I think this is due to the double "[[" on CollectionsContainer...

When I test with simple [ ], i have no problem to recup the field.

Anyone got an idea?

Thx

Labels (3)
1 Solution

Accepted Solutions
gjeremy1617088143

Hi, you can use JsonPath instead of Xpath (in the read by field in your component) set the Jsonpathquery to : "$.CollectionsContainer[*].[*]"

and Json query of your column to : "AccessProfileID".

Send me Love and Kudos

View solution in original post

2 Replies
gjeremy1617088143

Hi, you can use JsonPath instead of Xpath (in the read by field in your component) set the Jsonpathquery to : "$.CollectionsContainer[*].[*]"

and Json query of your column to : "AccessProfileID".

Send me Love and Kudos

PeterS3
Contributor
Contributor
Author

Thanks you gjeremy, it works!

It seems so simple I wonder why I haven't tested this before ...😑