Skip to content

Is there a built-in framework utility to convert a PL/SQL record (or array of records) from a custom projection's structure into a JSON CLOB, and back, rather than having to build the JSON manually field by field — useful for logging large request/response payloads to a CLOB column?

Answer

Yes — add the ReadAndWrapWithJson property (and/or ReadAndWrapWithXml, if you need XML too) to the relevant structure in your projection definition, for example: structure Expose using MyEntity { nestedwithcrud = ReadAndWrapWithJson, ReadAndWrapWithXml, Create; }. The code generator then automatically generates conversion methods for that structure that take the PL/SQL record/array and return a Json_Object_T (and the reverse), instead of you having to hand-build the JSON serialization logic yourself.

← Browse Developer Studio, deployment, and upgrades questions