rc); sqlite3_close(db); return -1; } for (i = 0; i < 100000000; i++) { memset (tmp_str, 0, sizeof(tmp_str)); sprintf (tmp_str, "col1%09d", i); sqlite3_bind_text (stmt, 1, tmp_str, -1, SQLITE_STATIC)
I'm not an expert, but I suspect it's the SQL_STATIC that's causing the problem. This means SQLite doesn't take a copy of your data and so when you do the sqlite3_step, all values are the same. Try SQL_TRANSIENT.