I don't have access to a machine right now with SQL/JSON support so this
might not work as is, but I think you will need a JSON object inside and
outside the array and an array aggregate function, something like this:
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.