Igor, I have a question.
Why is it "highly recommended" to use the function call sequence you iterate in preference to the sqlite3_exe call, since it is implemented using that sequence? Lee Crain _________________________________ -----Original Message----- From: Igor Tandetnik [mailto:[EMAIL PROTECTED] Sent: Sunday, October 07, 2007 9:44 AM To: SQLite Subject: [sqlite] Re: Callback fonction really not flexible to use [EMAIL PROTECTED] wrote: > Here a sample (in c) of the use i would like to do with sqlite > fucntion1() call fonction2() where is sqlite3_exec() > Callback function is the function3() and i would like to add data > in an array, which is retuned to function1() after the call of > function(2). > How i can do that ? does the Callback function can return > something else than an int ? A callback function must return 0. Any non-zero return value is an error indicator. However, the callback can, and usually does, have side effects. The void* parameter you pass to sqlite3_exec is passed through to the callback. Normally, this points to some kind of a data structure that the callback modifies. Having said that, be aware that sqlite3_exec is retained for backward compatibility only. It is highly recommended for new code to use API like sqlite3_prepare, sqlite3_step, sqlite3_finalize, sqlite3_column_* to iterate over the resultset. In fact, sqlite3_exec itself is implemented entirely in terms of these public API functions. Igor Tandetnik -------------------------------------------------------------------------- --- To unsubscribe, send email to [EMAIL PROTECTED] -------------------------------------------------------------------------- --- ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------