Navigation Bar

Tuesday, May 20, 2025

Working with JSONs in Oracle

JSON (JavaScript Object Notification ) is a text based format for storing and exchanging data in a way that is both human-readable and machine parsable. It is a well formed readable data format that simplifies data interchange across diverse platforms and programming languages. It is a very usefule data format for web developers, data analysts, software engineers and programmers in general.

It is a lightweight data interchange format that provides a standardized and efficient way for different systems to exchange data. Thanks to its simplicity, flexibility and compatibility, with a majority of the programming languages, it has become a cornerstone for building web applications a enjoys good support in the developer community.

When working with JSON, the basic necessities that a programmer will require are

An introduction to working with JSON data in Oracle using PLSQL

PL/SQL Object Types and Methods for JSON

Querying a JSON column tags from an oracle database table

  • Select JSON tag and value columns from the database
  • Query JSON data using JSON tags in the where clause

Oracle JSON : Select Level 1 and Level 2 data

Update individual JSON tag values.
Oracle JSON_MERGEPATCH updates

For more advanced programming using JSON, you should be able to

Parse through the entire JSON and to manipulate JSON tag values.

Parsing a JSON object with Oracle PLSQL

A generic JSON parser with Oracle PL/SQL

Parsing and updating a JSON object using PLSQL

A generic multi level JSON object parse and update script using PLSQL

A generic JSON parser with update using Oracle PL/SQL

A generic JSON parser and JSON generator using a config table

Generate JSONs by querying data from various tables to build a JSON in a given format.

A JSON generator using SQL and PLSQL

A generic JSON generator using a config table

Once you are familiar with these tasks, working with JSONs becomes more exciting and challenging to work with.

You should be able to convert JSON data to XML and vice versa.

XML to JSON and JSON to XML

For more interesting and informative reading on JSON you can refer the links below
What is JSON?(JavaScript Object Notation) 
Autonomous JSON Database

God's Word for the day

Do not pick a fight with the quick tempered
  And do not journey with them through lonely country
Because bloodshed means nothing to them
  and where no help is at hand they will strike you down.
Do not consult with fools, for they cannot keep a secret
  In the presence of strangers, do nothing that is to be kept a secret.
For you do not know what they will divulge
  Do not reveal your thoughts to anyone.
Or you may drive away your happiness.
Sirach 8:16-19

No comments:

Post a Comment