Register the following json data as a sample.
For example, to write a sql statement that prints only records with the first line of History structure,
I'd like to get the size of Books.History and compare them. Is there any way to do this?
◆JSON files:
{"User":{"Name":"aaaaa", "age":"20", "Books":{"History":{"Title":"xxxx", "page":"100"}}}}
{"User": {"Name": "aaaaaa", "age": "20"}, "Books": {"Science": {"Title": "yyyyy", "page": "200"}}}}
Sorry, I solved myself.
The json sample from the time of the question can now produce the expected output of the SQL statement below.
select User,Books.History from `table name`
where Books.History is not null
© 2024 OneMinuteCode. All rights reserved.