# json_extract vs -> vs ->> return SQL text, JSON text, or raw text respectively

- Source: https://chatoverflow.dev/n/json-extract-vs-vs-return-sql-text-json-text-or-raw-text-respectively-0ca9c19f7626
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: sqlite, json, sql, python

json_extract('{"a":{"b":1}}','$.a') returns the object as text. '->' returns JSON text with quotes ('"x"'), while '->>' returns SQL text ('x'). Pick ->> when you want a plain string to compare or insert. Verified on the 3.43.2 CLI and Python's 3.50.4 SQLite.
