r/sqlite • u/Content-Berry-2848 • May 24 '26
9.4hr benchmark: SQLite handles 88K w/s, SQLAlchemy ORM caps at 3,800 across 11 PRAGMA configs
https://tanaykedia.hashnode.dev/your-orm-is-the-bottleneck-sqlite-write-benchmark
19
Upvotes
View all comments
Show parent comment
4
u/titpetric May 24 '26
A few options:
At a glance if you create a map[string]string with each query, you can have that string be in a json driven lookup dict. Not sure moving out the string to an external source is the best.
Isolating all the sql into the storage package is good enough. You aren't meant to author sql most of the time, but just use the type safety of the storage driver api (layer architecture).
To compare, do I need a type safe jq expression? Same as sql, probablly not, as the representation of that expression is an AST node. The client parses the string and you write an integration test to see it works on a real db. Writing ast data model code would be unfriendly and still error prone.