They are useful - but not win this case as Booth's json was valid - and because Scott's examples don't show what the json looks like you can't learn from it in terms of formulatting the SQL to process it.

I think I'll write to Scott and suggest he add the JSON detail as a comment.

On Nov 15, 2019, at 4:43 PM, Bryan Dietz <bdietz400@xxxxxxxxx> wrote:

I've not digested exactly what is happening, but Scott Forstie has a repository on github for SQL snippets.

He has one that talks about json shredding
"JSON_TABLE and survival tips for shredding JSON with SQL"

maybe it helps


Jon Paris wrote on 11/15/2019 1:28 PM:
I played around with it Booth - once I had the format of the json - but could not get it to work. There are some real oddball things in SQL Json processing that I can't get my head around.
I don't believe it is the httpgetclob that gives you a problem because if you just feed the json into json_table like I did below I could still not get int to work. Is it possible that the form of this particular array data is one of the edge cases that SQL cannot handle? I don't know.
This is the Web Enabling the IBM i (AS/400 and iSeries) (WEB400) mailing list
To post a message email: WEB400@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
or email: WEB400-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives

As an Amazon Associate we earn from qualifying purchases.

This thread ...


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

This mailing list archive is Copyright 1997-2022 by 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.