5 Minutes

sqlite3 in 5 minutes or less?

A too brief introduction to sqlite3 is available at the sqlite website on the quickstart page.

Basically, you just need to use:


I've put up some code (both C and C++). This code is based on the code in the quickstart -- and uses the "exec" call to do the SQL -- which means it requires a "callback" function. Also, buried in the docs it is stated that usage of "exec" is deprecated and use of "prepare" (v2) plus "step" is preferred. In any case, this is just an example.

sqlite3 in a little more than 5 minutes ...

The C/C++ API page is actually pretty good, although it needs to be studied.

  • sqlite3 items begin with the prefix "sqlite3_" (as opposed to "sqlite_").
  • sqlite3 uses void* for the C UTF-16 data.