SQLite Forum

sqlite3_exec: the 3rd argument
Login
I figured out this one:

>\4. My callback function consistently fails on the second call: any ideas on how to overcome this? (I'm using C#)

The [reason is:](https://www.sqlite.org/c3ref/exec.html)

>If an sqlite3_exec() callback returns non-zero, the sqlite3_exec() routine returns SQLITE_ABORT without invoking the callback again and without running any subsequent SQL statements.

My callback was returning 1; however, returning 0, I encounter the same error on the 6th iteration irrespective of the number of columns in the result. <sup>(... more to do with my code).</sup>