I have a table like this:
TestTable
---------
data (TEXT)
All data values are JSON objects like { a:1, b:2, c:3 }.
I want to be able to query the database and ORDER BY data->b DESC without a full table scan (indexed).
Is this possible in SQLite JSON1?
Use the function
json_extract():See the demo.
If the values for
bare quoted then cast to numeric:See the demo.