Executable Is a SQLite Database
- ID
- 17386
- Status
- summarized
- Published
- 24 Aug 2026, 12:48 PM
- Fetched
- 26 Aug 2026, 11:15 AM
- Provider
- Hacker News
- Category
- dev-community
- Original URL
- https://fzakaria.com/2026/08/23/your-executable-is-a-sqlite-database
- Source URL
- https://hnrss.org/best
Summary
- Score
- 4.5
- Created
- 26 Aug 2026, 11:16 AM
- Tags
- Audience
- developersdatabase_learners
What happened
Farid Zakaria presents SELF (Structured Executable & Linkable Format), a working prototype where the executable file itself is a SQLite 3.x database that you can chmod +x and run. The core argument is that ELF already reinvents database primitives by hand—string interning, indexes, foreign keys, record layouts—and replacing them with SQLite would eliminate redundant parser/serializer implementations across the kernel, ld.so, binutils, readelf, and libraries like LIEF and goblin.
Why it matters
This is a research prototype, not something to adopt, but it reframes how you think about binary formats: ELF's .strtab is string interning, .gnu.hash is an index, section headers are a schema table. If you ever parse or manipulate ELF files, the SQL-based approach (e.g., SELECT soname FROM ldd) is a concrete alternative worth experimenting with via the sqlelf tool on GitHub.
Discussion angle
Walk through the mapping table (ELF mechanism → database primitive) live and debate whether SQLite-as-executable is a thought experiment or has a real niche—e.g., for supply-chain analysis, reproducible builds, or Nix-style declarative tooling where querying binaries declaratively adds value.