-- group: writes -- 2,000 INSERTs in one transaction, each under a savepoint of its own that is -- released, as a host that nests each write in a savepoint runs them. CREATE TABLE t1 (a INTEGER PRIMARY KEY, b INTEGER, c TEXT); BEGIN; -- repeat 2000 SAVEPOINT s; INSERT INTO t1 (a, b, c) VALUES ($i, ($i * 2654435761) % 20000, 'row-$i'); RELEASE s; COMMIT;