As many readers will be aware, we introduced a cool new JSON datatype in 21c which offers more features and better performance for JSON related features.

image

Of course, whilst a new datatype is all well and good for 21c, many of us are not planning on moving to 21c because 19c is the long term support release, and so the intention will be to stay on 19c until the next long term support release comes out.

Alas for 19c, there is no such datatype.

image

But here’s a little tip for those of you that are running on Autonomous Database. Even if you are on 19c, then even though the entire suite of 21c JSON-related features are not available, you can still get the benefits of the new and improved JSON storage by simply modifying the DDL you use to create your JSON segments.

image

Note that this is only supported on Autonomous, and if you are on the Autonomous JSON database, this is automatically taken care of.

Happy JSON-ing!

4 responses to “Juice up your JSON on Autonomous”

  1. Rajeshwaran Jeyabal Avatar
    Rajeshwaran Jeyabal

    No, not just Autonomous – even on 19c (19.14) running on Exacc platform supported.

    demo@PDB19> create table t (x json);
    create table t (x json)
    *
    ERROR at line 1:
    ORA-00902: invalid datatype

    demo@PDB19> create table t (x blob check(x is json format oson) );

    Table created.

    demo@PDB19> select banner_full from v$version;

    BANNER_FULL
    ————————————————————————–
    Oracle Database 19c EE Extreme Perf Release 19.0.0.0.0 – Production
    Version 19.14.0.0.0

    1. There is a HUGE difference between “runs” and “supported”. This facility is only supported on Autonomous.

      https://docs.oracle.com/en/database/oracle/oracle-database/19/adjsn/overview-of-storage-and-management-of-JSON-data.html

  2. Let’s say you have a column J19C in format OSON and I have a column J21C as a JSON data type. Once we both move to the *next* long term support release, will your DDL still work? Will both columns then benefit from the same full range of JSON capabilities?

  3. […] there is a better way. As I’ve covered in a previous post, if I am going to use BLOB format, I may as well take the opportunity to take advantage of the OSON […]

Leave a reply to stewashton Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Trending