Bench notes

Short technical field notes on systems weirdness

24 Dec 2025

Sqlite parses JSON in ZIP files

Pondering over Sqlite’s CLI documentation and discovered if one invokes sqlite3 with a .zip or .jar file, sqlite will synthesize a zip table of its contents. Thus one can read files from a .zip using Sqlite3. Internally, I believe it uses the zipfile() builtin function. Next, I totally forgot Sqlite has built-in JSON helpers. -> extracts a string, ->> extracts primitive JSON data types in addition to strings (no containers!). There’s also $, $[N] (where N is a number), and $.key (where key is a JSON property name).

Check out this command.

sqlite3 ~/.minecraft/versions/1.21.7/1.21.7.jar \
        "select json(data)->'translation.test.none' from zip
        where name = 'assets/minecraft/lang/en_us.json';"
Hello, world!

Pretty dang neat