1

I like to do a select query with a where condition on a column of type NCLOB let's call it information column. It has following format:

{ "firstName" : "name1", "lastName" : "lastName1" }

I want to do some thing like this

Select * from myTable where information.firsName = "targetName"

But I am not sure how to do it.

Any hints please?

Sandra Rossi
  • 11,934
  • 5
  • 22
  • 48
Sarah Jeffi
  • 53
  • 2
  • 10

1 Answers1

5

Looks like you want a structured database instead of a JSON clob... :)

Why don't you have a look at the JSON functions in HANA?

With JSON_TABLE you can construct a table structure "over" the JSON-data in the clob-column and then query that table structure.

Lars Br.
  • 9,949
  • 2
  • 15
  • 29