ChunkyKs' sqlite3 stuff
License:
In the spirit of SQLite, this stuff is all effectively public domain
unless stated otherwise in the code:
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.
C Examples:
Prepare, bind, step: The most important thing you need to know:
[bind?]
sqlite3_example_bind.c
How to insert whole files in as blobs without needing much memory:
sqlite3_example_blob.c
How to use zTail to execute multiple SQL statements catenated together:
sqlite3_example_ztail.c
Render database to directed graph:
Tool to make directed graphs:
sqlite3todot.tar.gz [current HEAD] github simple example complex example
Older version [much simpler to understand, though]:
sqlite3todot.old.c example
PHP Examples:
PDO example - or, how to avoid SQL injection attacks in your website:
php_example_pdo.php
Show working
Brainfuck interpreter
A BF interpreter written using only recursive common table expressions:
bf.sql.txt
EVAL():
Do not use this.
PLOT():
Hokey, using gnuplot
Porting to Postgres:
Recently I made a model I work on work with Postgres as well as SQLite:
Porting SQLite code to Postgres
MCMSQLiteBrowser:
A SQL gui whose redeeming quality is the ability to render charts
Gary "ChunkyKs" Briggs <chunky@icculus.org>