exec sql select * into :wCount, :wSeas
             from json_table(systools.httpgetclob(:wURL, ''), '$'
               columns(
                 "wData_length" dec(3,0),
                 SeasOceans varchar(20) PATH 'lax $.SeasOceans[4]' ));

also works, in that it gives me the count and element[4].

For collecting an array, "nested" seems to be the correct word, probably also needing ''lax $'.  I suspect the issue involves either the SQLRPGLE usage, or more likely, programmer error.  I did try to loop.  That gave me element 1 repeatedly;  I could not find a way to use a variable in place of the $.SeasOcceans[4] and using an * instead of the 4 failed.


..On 11/17/2019 6:02 PM, Jon Paris wrote:
It is going to return a row for each element Booth so you'll probably need to use a cursor.

Does it work without nested?


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.