Since this topic has lead to different sub-topic I dare ask a question (I'm a beginner both in C++ and, Oh boy, in SQLite too).
Tito, do you really need the 5th argument in sqlite3_prepare_v2() i.e. "&oneSQL"? >From what I understand from your code, there's only one SQL statement to be prepared, so there would be no need for the supposedly next SQL statement. Do you reuse (reset) these statements? I was under the impression that the 5th argument is used when the SQL statement string contains more than one SQL statement. Thanks for your patience if I misunderstood something .. or all. Marian Cascaval ________________________________ From: Tito Ciuro <tci...@mac.com> To: General Discussion of SQLite Database <sqlite-users@sqlite.org> Sent: Mon, January 31, 2011 9:38:57 PM Subject: [sqlite] Second sqlite3_prepare_v2() call fails on iOS path-based databases // Build the first statement sqlite3_stmt *oneStatement = NULL; const char *oneSQL = [[NSString stringWithFormat:@"INSERT INTO %@(%@, %@, %@, %@) VALUES (?,?,?,?);", NSFValues, NSFKey, NSFAttribute, NSFValue, NSFDatatype]UTF8String]; int statusOne = sqlite3_prepare_v2(db, oneSQL, (int)strlen(oneSQL), &oneStatement, &oneSQL); _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users