> Le 1 sept. 2017 à 03:43, Papa <p...@arbolone.ca> a écrit : > > std::string sql_statement_request; > ... > rc = sqlite3_prepare_v2(db, > sql_statement_request.data(), > -1,
The (calling program) bug starts here above. sql_statement_request.data() is not guaranteed to be zero-terminated (and generally isn't). You either have to do: > rc = sqlite3_prepare_v2(db, > sql_statement_request.c_str(), > -1, Or > rc = sqlite3_prepare_v2(db, > sql_statement_request.data(), > (int)sql_statement_request.size(), Whatever else might happen to be wrong with this query, chances are SQLite parses a longer string than you intended and might fail with syntax errors, which would explain you get a null statement pointer. -- Best Regards, Meilleures salutations, Met vriendelijke groeten, Olivier Mascia, http://integral.software _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users