Skip to Main Content

ORDS, SODA & JSON in the Database

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to SELECT list of attributes in a collection?

Bud Endress - Oracle-OracleMar 1 2018 — edited Mar 6 2018

I'm looking for a way to select a list of attribute names from a collection using SELECT, hopefully something that is just built into Oracle JSON support.  (I know I can write some PLSQL that will parse the collection.  I'm hopefully for something native to the JSON implementation as it might be more reliable in the long run.)

For example, I have a collection such as this stored in a column of a table as JSON.

{"year_name":CY2011,"quarter_name":Q2CY2011,"month_name":Apr-11}

and I would like a SELECT that returns:

year_name

quarter_name

month_name

Thanks,

- B

This post has been answered by thatJeffSmith-Oracle on Mar 1 2018
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 3 2018
Added on Mar 1 2018
6 comments
927 views