3 ms·
One of the better commentaries on just how light sqlite is was in apenwarr's redo FAQ[1] > ... I think people underestimate how "lite" sqlite really is:
by aidenn0 4y ago
One of the better commentaries on just how light sqlite is was in apenwarr's redo FAQ[1]
> ... I think people underestimate how "lite" sqlite really is:
root root 573376 2010-10-20 09:55 /usr/lib/libsqlite3.so.0.8.6
> 573k for a complete and very fast and transactional SQL database. For comparison, libdb is:
root root 1256548 2008-09-13 03:23 /usr/lib/libdb-4.6.so
> ...more than twice as big, and it doesn't even have an SQL parser in it! Or if you want to be really horrified:
root root 1995612 2009-02-03 13:54 /usr/lib/libmysqlclient.so.15.0.0
> The mysql client library is two megs, and it doesn't even have a database in it! People who think SQL databases are automatically bloated and gross have not yet actually experienced the joys of sqlite. SQL has a well-deserved bad reputation, but sqlite is another story entirely. It's excellent, and much simpler and better written than you'd expect.
1: https://redo.readthedocs.io/en/latest/FAQImpl/ https://redo.readthedocs.io/en/latest/FAQImpl/
- sgbeal 4y ago> root root 573376 2010-10-20 09:55 /usr/lib/libsqlite3.so.0.8.6 In all fairness, though: sqlite3 was much smaller in 2010 ;). Similarly, libdb and libmysqlclient were probably smaller in 2008/2009. My locally-installed copy of today's trunk version of libsqlite3 (pre-3.39), on x86_64, stripped of debug symbols, is 1.27MB.
- chasil 4y agoYou can keep using those. The database format is defined as a long-term storage format by the U.S. Library of Congress. https://www.sqlite.org/locrsf.html https://www.sqlite.org/locrsf.html There have been a lot of new features over the new years, the latest being window functions. Those features do not impact the database file format. Embedded systems that don't need these features probably haven't upgraded.
- masklinn 4y ago> There have been a lot of new features over the new years, the latest being window functions. Window functions were added in 3.25, 4 years ago. Since then sqlite added a bunch of stuff like RETURNING clauses, upserts, json operators (and enabled json functions by default though they’d been there a while), update from, generated columns, …
- aidenn0 4y agoJust checked on my system: 1.9MB for libdb-5 vs 1.2MB for libsqlite3 on My Machine(TM)