SQL Language (MOSC)

MOSC Banner

Is it possible to set SQL/JSON queries to return clob as default

edited Sep 30, 2020 1:29PM in SQL Language (MOSC) 4 commentsAnswered ✓

Hi,

I'm using Oracle DB 19c (19.0.0.0.0) SQL/JSON queries in PL/SQL: json_arrayagg, json_object etc. with large quantity of nested data and need to set the "returning clob" option everywhere.

Is there any way to set the default json_* function to return clobs?

  select json_serialize(            
            json_arrayagg(
                json_object(
                  'id'     value name,
                  'doc'    value doc
                  returning clob
                )
            returning clob
            )
         returning clob pretty)
  select * from mytable
      

  

  

  

  

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center