Skip to content
Advertisement

How to filter json in PLSQL?

My data look like:

I want to select only data where EVENT_PAYLOAD type is “page”.

I’ve written:

Help would be appreciated. Thanks!

Advertisement

Answer

If you have properly declared the JSON column, you can just use the dot notation to access a JSON value by key:

Alternatively, you can use json_value():

Demo on DB Fiddle

User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement