
Size isn't everything for the modest creator of SQLite (2007) - mbgaxyz
http://www.theguardian.com/technology/2007/jun/21/it.guardianweeklytechnologysection
======
smadge
Hacker news is too often obsessed with get rich quick schemes, and devising
new ways to rip people off. It's nice to hear a story about people who just
wants to write good, useful software, and release it to the public domain.

------
sehugg
_So how many SQLite databases are in use? "We don't have a good way of
counting it," he says, "but we're guessing it's the most widely deployed SQL
database in the world."_

This article came out before the original iPhone was released -- it certainly
is by now, probably by an order of magnitude.

~~~
abtinf
Just "an order of magnitude"? I suspect you are off by an order of magnitude.
If you count each deployed instance of each product using it, it's probably
the most popular by close to 10 orders of magnitude.

Edit: phones are just the start. Numerous embedded products use it - the kind
that ship in such large quantities that a couple pennies per device become
significant sums of money. And even in the phone case, every app is using a
separate database.

~~~
adrianN
10 orders of magnitude is a lot. Are you really saying there are ten billion
times more SQLlite databases than the next most popular SQL?

~~~
masklinn
That's probably excessive by a lot, but every modern smartphone has at least
one sqlite bundled (possibly more, some software will bundle their own in case
the system changes its version), OSX bundles it (and Apple Mail uses it for
some stuff), Chrome and Firefox bundle it, …

------
dang
We should have a bonus for finding great old articles that never were posted
to HN before.

There was another one earlier today:
[https://news.ycombinator.com/item?id=11048637](https://news.ycombinator.com/item?id=11048637).

~~~
bootload
yeah I'll take a look, @dang the web rusts a lot so a lot of old stuff might
be archived [0] there.

[0] Internet Archive [https://archive.org/](https://archive.org/)

~~~
greglindahl
For the future, HN's software could call the Wayback Machine's "save page now"
API on all front-page links.

~~~
dang
Definitely willing to do that. Lord knows we do it enough by hand already.

------
dalke
A nice interview, though from 2007. One thing has changed a smidgeon: "he has
a self-imposed limit on the size of his product: 250KB. And he's stuck to both
aims". The FAQ on sqlite.org says "With all features enabled, the library size
can be less than 500KiB ... If optional features are omitted, the size of the
SQLite library can be reduced below 300KiB." Close though!

~~~
nly
Also out of date. The 3.10.2 shared library is over 1 MiB on my system.

~~~
dalke
Compiling with -Os brings it down to 800 KB.

    
    
      % gcc -c sqlite3.c
      % ls -l sqlite3.o
      -rw-r--r--  1 dalke  admin  1270372 Feb  6 04:11 sqlite3.o
      % gcc -c sqlite3.c -Os
      % ls -l sqlite3.o
      -rw-r--r--  1 dalke  admin  805044 Feb  6 04:12 sqlite3.o
    
      % clang -c sqlite3.c
      % ls -l sqlite3.o
      -rw-r--r--  1 dalke  admin  1248704 Feb  6 04:15 sqlite3.o
      % clang -c -Os sqlite3.c
      % ls -l sqlite3.o
      -rw-r--r--  1 dalke  admin  796888 Feb  6 04:16 sqlite3.o
    

778 KiB is still some 50% larger than 500.

~~~
SQLite
Using "gcc -Os -m32 -c sqlite3.c; size sqlite3.o" I get 443,264 bytes using
the latest SQLite source on Ubuntu.

The "size" command gives a more accurate measurement of what actually ends up
in a compiled and stripped binary. "ls -l" includes symbolic and linking info
that gets stripped from the finished binary.

~~~
obelisk_
Are you the author of SQLite or did you just name your account so for other
reasons?

~~~
SQLite
Yes, I am.

~~~
orvr
May I ask you about the current state of sqlite4?

------
matt_wulfeck
> The author disclaims copyright to this source code. In place of a legal
> notice, here is a blessing: may you do good and not evil. May you find
> forgiveness for yourself and forgive others. May you share freely, never
> taking more than you give.

Wow! That is the most enlightened disclaimer I've ever read.

------
ksec
what happened to SQLite 4?

~~~
maaku
This is from 2007.

