That function expects a sequence of database names but now it is supplied with JSON that has both the database name and the count of documents.
Easy fix is probably to add '/names' on the call to lib-adhoc:get-databases() to extract just the database names. We might also want to send a param to lib-adhoc:get-databases that determines if the counts are calculated also since we don't always want/need the counts.
Also as part of this, look at all calls to lib-adhoc:get-databases() and make sure they are set for the JSON (name/count) response.
When clicking the Select Fields button in the adhoc wizard, an error is displayed on the screen and the following is in the log:
To recreate:
It looks to me like the error occurs in api-adhoc-query-wizard.xqy in the following line:
That function expects a sequence of database names but now it is supplied with JSON that has both the database name and the count of documents.
Easy fix is probably to add '/names' on the call to lib-adhoc:get-databases() to extract just the database names. We might also want to send a param to lib-adhoc:get-databases that determines if the counts are calculated also since we don't always want/need the counts.
Also as part of this, look at all calls to lib-adhoc:get-databases() and make sure they are set for the JSON (name/count) response.