title: iPhone app crashes with sqlite3_bind_text()
body: <p>I'm attempting to make a simple app that stores and displays flash cards, however I'm having an awful time getting my SQLite to work. The database connection is fine, but when I try an insert, it crashes and gives no indication of what went wrong. This is the code I am using to insert the flash card into the table. </p>
  
  <pre><code>const char *insert = "INSERT OR REPLACE INTO LIST (TERM, DEFINITION) VALUES (?, ?);";
  sqlite3_stmt *statement;
  sqlite3_prepare_v2(database, insert, -1, &amp;statement, nil);
  sqlite3_bind_text(statement, 1, [term UTF8String], -1, SQLITE_TRANSIENT);
  sqlite3_bind_text(statement, 2, [def UTF8String], -1, SQLITE_TRANSIENT);
  sqlite3_step(statement);
  sqlite3_finalize(statement);
  </code></pre>
  
  <p>I've determined that the bind text method is the weak link with some NSLog() methods I placed earlier. In this example, term and def are NSStrings that do hold the correct value (I know that much for sure). Any help would be appreciated. I haven't quite mastered portable c.</p>