On Sat, 2005-03-26 at 15:15 -0600, Eric Bohlman wrote: > #define SEX "'M'" > > sqlite3_bind_text(stmt, index, SEX, sizeof(SEX), > > SQLITE_TRANSIENT);
[note the extra ' in SEX] > Change sizeof to strlen here (and in the corresponding statement below); > sqlite3_bind_text wants the length of the string, not the size of the > pointer to it. sizeof(SEX)-1 is fine.