I created the SQL for creating and filling a table in a large existing SQLite database:
CREATE TABLE ...;
INSERT INTO ...;
INSERT INTO ...;
...
Then sent it to sqlite3. Irrespective of what way I read the commands (e.g. "sqlite3 db < create.sql", or ".read create.sql" in the SQLite prompt), executing each line took close to a second, even though each line only consisted of two strings.
What is causing SQLite to work so slowly? How can I speed it up?