Hacker News

Favorites Setup
Comment by inigyou | original | SQLite as a Document Database (2020)
[−]inigyou · 2026-08-29 Sat 18:54 UTC · link
Postgres does even better and it's available right now. No virtual column needed.

    CREATE TABLE t1 (data JSONB);
    INSERT INTO t1 VALUES ('{"column1":1234}');
    CREATE INDEX t1column1 ON t1(data->'column1');
    SELECT * FROM t1 WHERE data1->'column1' = '1234'; // not sure about data type
[−]mathnode · 2026-08-29 Sat 20:01 UTC · link
I would not call an index format which gets slower with growth "better". And that vacuum issue on JSONB scales with your data size.
[−]inigyou · 2026-08-29 Sat 20:59 UTC · link
What do you mean slower with growth? What vacuum issue?
[−]sgt · 2026-08-30 Sun 10:24 UTC · link
Who wants to tell him?